Merge "Avoid races in MessageCache::replace()"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Thu, 26 Jan 2017 00:53:11 +0000 (00:53 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Thu, 26 Jan 2017 00:53:11 +0000 (00:53 +0000)
38 files changed:
includes/Sanitizer.php
includes/Setup.php
includes/skins/SkinTemplate.php
includes/specials/SpecialUserrights.php
includes/upload/UploadBase.php
languages/i18n/ar.json
languages/i18n/be-tarask.json
languages/i18n/bs.json
languages/i18n/da.json
languages/i18n/de.json
languages/i18n/en.json
languages/i18n/es.json
languages/i18n/eu.json
languages/i18n/fr.json
languages/i18n/hr.json
languages/i18n/io.json
languages/i18n/it.json
languages/i18n/ko.json
languages/i18n/lfn.json
languages/i18n/mk.json
languages/i18n/my.json
languages/i18n/qqq.json
languages/i18n/ru.json
languages/i18n/sh.json
languages/i18n/sl.json
resources/Resources.php
resources/src/mediawiki.rcfilters/dm/mw.rcfilters.dm.FilterItem.js
resources/src/mediawiki.rcfilters/dm/mw.rcfilters.dm.FiltersViewModel.js
resources/src/mediawiki.rcfilters/mw.rcfilters.Controller.js
resources/src/mediawiki.rcfilters/mw.rcfilters.init.js
resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterCapsuleMultiselectWidget.less
resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterWrapperWidget.less
resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FilterCapsuleMultiselectWidget.js
resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FilterWrapperWidget.js
resources/src/mediawiki.skinning/content.css
tests/parser/ParserTestRunner.php
tests/parser/parserTests.txt
tests/qunit/suites/resources/mediawiki.rcfilters/dm.FiltersViewModel.test.js

index 6779189..42b166d 100644 (file)
@@ -1119,6 +1119,7 @@ class Sanitizer {
                        '>'    => '&gt;',   // we've received invalid input
                        '"'    => '&quot;', // which should have been escaped.
                        '{'    => '&#123;',
+                       '}'    => '&#125;', // prevent unpaired language conversion syntax
                        '['    => '&#91;',
                        "''"   => '&#39;&#39;',
                        'ISBN' => '&#73;SBN',
index ecd164d..01ba1e8 100644 (file)
@@ -244,7 +244,7 @@ if ( $wgUseInstantCommons ) {
                'transformVia404' => true,
                'fetchDescription' => true,
                'descriptionCacheExpiry' => 43200,
-               'apiThumbCacheExpiry' => 86400,
+               'apiThumbCacheExpiry' => 0,
        ];
 }
 /*
index 1a4554f..bf260aa 100644 (file)
@@ -1322,7 +1322,7 @@ class SkinTemplate extends Skin {
                        if ( !$user->isAnon() ) {
                                $sur = new UserrightsPage;
                                $sur->setContext( $this->getContext() );
-                               $canChange = $sur->userCanChangeRights( $this->getUser(), false );
+                               $canChange = $sur->userCanChangeRights( $user );
                                $nav_urls['userrights'] = [
                                        'text' => $this->msg(
                                                $canChange ? 'tool-link-userrights' : 'tool-link-userrights-readonly',
index 4db2198..b1f8a17 100644 (file)
@@ -49,19 +49,25 @@ class UserrightsPage extends SpecialPage {
        }
 
        /**
-        * @param User $user
-        * @param bool $checkIfSelf
+        * Check whether the current user (from context) can change the target user's rights.
+        *
+        * @param User $targetUser User whose rights are being changed
+        * @param bool $checkIfSelf If false, assume that the current user can add/remove groups defined
+        *   in $wgGroupsAddToSelf / $wgGroupsRemoveFromSelf, without checking if it's the same as target
+        *   user
         * @return bool
         */
-       public function userCanChangeRights( $user, $checkIfSelf = true ) {
+       public function userCanChangeRights( $targetUser, $checkIfSelf = true ) {
+               $isself = $this->getUser()->equals( $targetUser );
+
                $available = $this->changeableGroups();
-               if ( $user->getId() == 0 ) {
+               if ( $targetUser->getId() == 0 ) {
                        return false;
                }
 
                return !empty( $available['add'] )
                        || !empty( $available['remove'] )
-                       || ( ( $this->isself || !$checkIfSelf ) &&
+                       || ( ( $isself || !$checkIfSelf ) &&
                                ( !empty( $available['add-self'] )
                                        || !empty( $available['remove-self'] ) ) );
        }
@@ -465,29 +471,6 @@ class UserrightsPage extends SpecialPage {
                );
        }
 
-       /**
-        * Go through used and available groups and return the ones that this
-        * form will be able to manipulate based on the current user's system
-        * permissions.
-        *
-        * @param array $groups List of groups the given user is in
-        * @return array Tuple of addable, then removable groups
-        */
-       protected function splitGroups( $groups ) {
-               list( $addable, $removable, $addself, $removeself ) = array_values( $this->changeableGroups() );
-
-               $removable = array_intersect(
-                       array_merge( $this->isself ? $removeself : [], $removable ),
-                       $groups
-               ); // Can't remove groups the user doesn't have
-               $addable = array_diff(
-                       array_merge( $this->isself ? $addself : [], $addable ),
-                       $groups
-               ); // Can't add groups the user does have
-
-               return [ $addable, $removable ];
-       }
-
        /**
         * Show the form to edit group memberships.
         *
index 96f8638..79166ef 100644 (file)
@@ -1440,6 +1440,7 @@ abstract class UploadBase {
                        'http://www.w3.org/1999/02/22-rdf-syntax-ns#',
                        'http://www.w3.org/2000/svg',
                        'http://www.w3.org/tr/rec-rdf-syntax/',
+                       'http://www.w3.org/2000/01/rdf-schema#',
                ];
 
                // Inkscape mangles namespace definitions created by Adobe Illustrator.
index 0376f42..156efdb 100644 (file)
        "recentchanges-legend-newpage": "{{int:recentchanges-label-newpage}} (راجع أيضا [[Special:NewPages|قائمة الصفحات الجديدة]])",
        "recentchanges-submit": "أظهر",
        "rcfilters-activefilters": "المرشحات النشطة",
+       "rcfilters-restore-default-filters": "استرجاع المرشحات الافتراضية",
+       "rcfilters-clear-all-filters": "مسح كل المرشحات",
        "rcfilters-search-placeholder": "رشح أحدث التغييرات (تصفح أو ابدأ الكتابة)",
        "rcfilters-invalid-filter": "مرشح غير صحيح",
+       "rcfilters-empty-filter": "لا مرشحات فعالة. كل المساهمات معروضة.",
        "rcfilters-filterlist-title": "مرشحات",
        "rcfilters-filterlist-noresults": "لم يتم العثور على مرشحات",
+       "rcfilters-filtergroup-registration": "تسجيل المستخدم",
+       "rcfilters-filter-registered-label": "مسجل",
+       "rcfilters-filter-registered-description": "المحررون مسجلو الدخول.",
+       "rcfilters-filter-unregistered-label": "غير مسجل",
+       "rcfilters-filter-unregistered-description": "المحررون غير مسجلي الدخول.",
        "rcfilters-filtergroup-authorship": "ملكية التعديلات",
        "rcfilters-filter-editsbyself-label": "تعديلاتك الشخصية",
        "rcfilters-filter-editsbyself-description": "التعديلات بواسطتك.",
        "rcfilters-filter-editsbyother-label": "التعديلات بواسطة الآخرين",
-       "rcfilters-filter-editsbyother-description": "التعديلات المنشأة بواسطة المستخدمين الآخرين (ليس أنت.)",
-       "rcfilters-filtergroup-userExpLevel": "Ù\85ستÙ\88Ù\89 Ø®Ø¨Ø±Ø© Ø§Ù\84Ù\85ستخدÙ\85",
+       "rcfilters-filter-editsbyother-description": "التعديلات المنشأة بواسطة المستخدمين الآخرين (ليس أنت).",
+       "rcfilters-filtergroup-userExpLevel": "Ù\85ستÙ\88Ù\89 Ø§Ù\84خبرة (Ù\84Ù\84Ù\85ستخدÙ\85Ù\8aÙ\86 Ø§Ù\84Ù\85سجÙ\84Ù\8aÙ\86 Ù\81Ù\82Ø·)",
        "rcfilters-filter-userExpLevel-newcomer-label": "القادمون الجدد",
-       "rcfilters-filter-userExpLevel-newcomer-description": "اÙ\84Ù\85ستخدÙ\85Ù\88Ù\86 Ø§Ù\84جدد Ø¬Ø¯Ø§: Ø£Ù\82Ù\84 Ù\85Ù\86 10 ØªØ¹Ø¯Ù\8aÙ\84ات Ù\884 Ø£Ù\8aاÙ\85 Ù\85Ù\86 Ø§Ù\84Ù\86شاط.",
+       "rcfilters-filter-userExpLevel-newcomer-description": "أقل من 10 تعديلات و4 أيام من النشاط.",
        "rcfilters-filter-userExpLevel-learner-label": "المتعلمون",
-       "rcfilters-filter-userExpLevel-learner-description": "المزيد من أيام النشاط والتعديلات أكثر من 'القادمين الجدد' ولكن أقل من 'المستخدمين ذوي الخبرة.'",
+       "rcfilters-filter-userExpLevel-learner-description": "المزيد من أيام النشاط والتعديلات أكثر من \"القادمين الجدد\" ولكن أقل من \"المستخدمين ذوي الخبرة\".",
        "rcfilters-filter-userExpLevel-experienced-label": "المستخدمون ذوو الخبرة",
        "rcfilters-filter-userExpLevel-experienced-description": "أكثر من 30 يوما من النشاط و500 تعديل.",
+       "rcfilters-filtergroup-automated": "المساهمات الأوتوماتيكية",
+       "rcfilters-filter-bots-label": "بوت",
+       "rcfilters-filter-bots-description": "التعديلات بواسطة الأدوات الأوتوماتيكية.",
+       "rcfilters-filter-humans-label": "بشري (ليس بوت)",
+       "rcfilters-filter-humans-description": "التعديلات بواسطة المحررين البشريين.",
+       "rcfilters-filtergroup-significance": "الأهمية",
+       "rcfilters-filter-minor-label": "تعديلات طفيفة",
+       "rcfilters-filter-minor-description": "التعديلات التي علم عليها المستخدم كطفيفة.",
+       "rcfilters-filter-major-label": "التعديلات غير الطفيفة",
+       "rcfilters-filter-major-description": "التعديلات غير المعلم عليها كطفيفة.",
+       "rcfilters-filtergroup-changetype": "نوع التغيير",
+       "rcfilters-filter-pageedits-label": "تعديلات الصفحة",
+       "rcfilters-filter-pageedits-description": "التعديلات لمحتوى الويكي، النقاشات، وصوفات التصنيفات....",
+       "rcfilters-filter-newpages-label": "إنشاء الصفحات",
+       "rcfilters-filter-newpages-description": "التعديلات التي تصنع صفحات جديدة.",
+       "rcfilters-filter-categorization-label": "تغييرات التصنيفات",
+       "rcfilters-filter-categorization-description": "سجلات إضافة أو إزالة الصفحات من التصنيفات.",
+       "rcfilters-filter-logactions-label": "الأفعال المسجلة",
+       "rcfilters-filter-logactions-description": "الأفعال الإدارية، إنشاء الحسابات، حذف الصفحات، عمليات الرفع....",
        "rcnotefrom": "بالأسفل {{PLURAL:$5|التغيير|التغييرات}} منذ <strong>$2</strong> (إلى <strong>$1</strong> معروضة).",
        "rclistfrom": "أظهر التغييرات بدء من $3 $2",
        "rcshowhideminor": "$1 التعديلات الطفيفة",
        "apisandbox-sending-request": "إرسال طلب API ...",
        "apisandbox-loading-results": "استقبال طلبات API ...",
        "apisandbox-results-error": "حدث خطأ أثناء تحميل رد استعدلام الAPI: $1.",
-       "apisandbox-request-params-json": "معاملات JSON:",
        "apisandbox-request-url-label": "مسار الطلب:",
        "apisandbox-request-time": "وقت الطلب: {{PLURAL:$1|$1 ms}}",
        "apisandbox-results-fixtoken": "رمز الصحيح وإعادة الموافقة",
        "usercssispublic": "من فضل لاحظ: صفحات الCSS الفرعية لا ينبغي أن تحتوي على بيانات سرية بما أنها يمكن رؤيتها بواسطة المستخدمين الآخرين.",
        "restrictionsfield-badip": "عنوان أيبي أو نطاق غير صحيح: $1",
        "restrictionsfield-label": "نطاقات الأيبي المسموح بها:",
-       "restrictionsfield-help": "عنوان أيبي أو نطاق CIDR واحد لكل سطر. لتفعيل كل شيء، استخدم<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "restrictionsfield-help": "عنوان أيبي أو نطاق CIDR واحد لكل سطر. لتفعيل كل شيء، استخدم:\n<pre>0.0.0.0/0\n::/0</pre>",
        "revid": "المراجعة $1",
        "pageid": "معرف الصفحة $1"
 }
index b7c3b18..1aa6e36 100644 (file)
        "undo-norev": "Рэдагаваньне ня можа быць адмененае, таму што яно не існуе альбо было выдаленае.",
        "undo-nochange": "Выглядае, што праўка ўжо была адмененая.",
        "undo-summary": "Скасаваньне праўкі $1 {{GENDER:$2|удзельніка|удзельніцы}} [[Special:Contributions/$2|$2]] ([[User talk:$2|гутаркі]])",
-       "undo-summary-username-hidden": "Ð\92Ñ\8dÑ\80Ñ\81Ñ\96Ñ\8f $1 Ñ\81каÑ\81аванаÑ\8f Ñ\81Ñ\85аванÑ\8bм Ñ\83дзелÑ\8cнÑ\96кам",
+       "undo-summary-username-hidden": "СкаÑ\81аванÑ\8cне Ð²Ñ\8dÑ\80Ñ\81Ñ\96Ñ\96 $1 Ñ\81Ñ\85аванага Ñ\9eдзелÑ\8cнÑ\96ка",
        "cantcreateaccount-text": "Стварэньне рахункаў з гэтага IP-адрасу ('''$1''') было заблякаванае [[User:$3|$3]].\n\nПрычына блякаваньня пададзеная $3: ''$2''",
        "cantcreateaccount-range-text": "Стварэньне рахункаў з IP-адрасоў у дыяпазоне <strong>$1</strong>, у які ўваходзіць ваш IP-адрас (<strong>$4</strong>), было забароненае {{GENDER:$3|ўдзельнікам|ўдзельніцай}} [[User:$3|$3]].\n\n{{GENDER:$3|Удзельнікам|Удзельніцай}} $3 была пададзеная наступная прычына: <em>$2</em>.",
        "viewpagelogs": "Паказаць журналы падзеяў для гэтай старонкі",
        "recentchanges-legend-newpage": "{{int:recentchanges-label-newpage}} (глядзіце таксама [[Special:NewPages|сьпіс новых старонак]])",
        "recentchanges-submit": "Паказаць",
        "rcfilters-activefilters": "Актыўныя фільтры",
+       "rcfilters-restore-default-filters": "Аднавіць фільтры па змоўчаньні",
        "rcfilters-search-placeholder": "Фільтар апошніх зьменаў (праглядзець або пачніце друкаваць)",
        "rcfilters-invalid-filter": "Няслушны фільтар",
        "rcfilters-filterlist-title": "Фільтры",
        "rcfilters-filter-userExpLevel-experienced-description": "Больш за 30 дзён актыўнасьці і 500 правак.",
        "rcfilters-filtergroup-automated": "Аўтаматычны ўнёсак",
        "rcfilters-filter-bots-label": "Робат",
+       "rcfilters-filter-bots-description": "Праўкі, зробленыя з дапамогай аўтаматызаваных інструмэнтаў.",
+       "rcfilters-filter-humans-label": "Чалавек (ня робат)",
        "rcnotefrom": "Ніжэй {{PLURAL:$5|знаходзіцца зьмена|знаходзяцца зьмены}} з <strong>$4 $3</strong> (да <strong>$1</strong> на старонку).",
        "rclistfrom": "Паказаць зьмены з $2 $3",
        "rcshowhideminor": "$1 дробныя праўкі",
index f6db0a0..2a17f15 100644 (file)
        "badsig": "Loš sirovi potpis.\nProvjerite HTML tagove.",
        "badsiglength": "Vaš potpis je predug.\nMora biti manji od $1 {{PLURAL:$1|znaka|znaka|znakova}}.",
        "yourgender": "Kako želite da se predstavite?",
-       "gender-unknown": "Kad vas spominje, softver će pokušati koristiti srednji rod kad god je to moguće",
+       "gender-unknown": "Kad Vas spominje, softver će pokušati izbjegavati rod kad god je to moguće",
        "gender-male": "On uređuje wiki stranice",
        "gender-female": "Ona uređuje wiki stranice",
        "prefs-help-gender": "Postavljanje ovih podešavanja nije obavezno.\nSoftver koristi ove vrijednosti za vaše naslovljanje i ispravke gramatičkog roda u porukama softvera. Ova će informacija biti javna.",
index 2a44a8b..c72b598 100644 (file)
        "patrol-log-header": "Patruljerede versioner.",
        "log-show-hide-patrol": "$1 patruljeringslog",
        "confirm-markpatrolled-button": "OK",
+       "confirm-markpatrolled-top": "Marker version $3 af $2 som patruljeret?",
        "deletedrevision": "Slettede gammel version $1",
        "filedeleteerror-short": "Fejl under sletning af fil: $1",
        "filedeleteerror-long": "Der opstod en fejl under sletningen af filen:\n\n$1",
index ec5969d..ec0313e 100644 (file)
        "recentchanges-legend-plusminus": "''(±123)''",
        "recentchanges-submit": "Anzeigen",
        "rcfilters-activefilters": "Aktive Filter",
+       "rcfilters-restore-default-filters": "Standardfilter wiederherstellen",
+       "rcfilters-clear-all-filters": "Alle Filter löschen",
        "rcfilters-search-placeholder": "Letzte Änderungen filtern (durchsuchen oder beginne mit der Eingabe)",
        "rcfilters-invalid-filter": "Ungültiger Filter",
+       "rcfilters-empty-filter": "Keine aktiven Filter. Es werden alle Beiträge angezeigt.",
        "rcfilters-filterlist-title": "Filter",
        "rcfilters-filterlist-noresults": "Keine Filter gefunden",
        "rcfilters-filtergroup-registration": "Benutzerregistrierung",
index f2ff14b..9f03ce9 100644 (file)
        "recentchanges-legend-plusminus": "(<em>±123</em>)",
        "recentchanges-submit": "Show",
        "rcfilters-activefilters": "Active filters",
+       "rcfilters-restore-default-filters": "Restore default filters",
+       "rcfilters-clear-all-filters": "Clear all filters",
        "rcfilters-search-placeholder": "Filter recent changes (browse or start typing)",
        "rcfilters-invalid-filter": "Invalid filter",
+       "rcfilters-empty-filter": "No active filters. All contributions are shown.",
        "rcfilters-filterlist-title": "Filters",
        "rcfilters-filterlist-noresults": "No filters found",
        "rcfilters-filtergroup-registration": "User registration",
index 7933b02..7b76946 100644 (file)
        "recentchanges-legend-newpage": "{{int:recentchanges-label-newpage}} (véase también la [[Special:NewPages|lista de páginas nuevas]])",
        "recentchanges-submit": "Mostrar",
        "rcfilters-activefilters": "Filtros activos",
+       "rcfilters-restore-default-filters": "Restaurar filtros predeterminados",
+       "rcfilters-clear-all-filters": "Borrar todos los filtros",
        "rcfilters-search-placeholder": "Filtrar cambios recientes (navega o empieza a escribir)",
        "rcfilters-invalid-filter": "Filtro no válido",
+       "rcfilters-empty-filter": "No hay filtros activos. Se muestran todas las contribuciones.",
        "rcfilters-filterlist-title": "Filtros",
        "rcfilters-filterlist-noresults": "No se encontraron filtros",
        "rcfilters-filtergroup-registration": "Registro de usuario",
index b14ceec..aba144a 100644 (file)
        "subcategories": "Azpikategoriak",
        "category-media-header": "Media \"$1\" kategorian",
        "category-empty": "''Kategoria honek ez dauka artikulurik uneotan.''",
-       "hidden-categories": "{{PLURAL:$1|Izkutuko kategoria|Izkutuko kategoriak}}",
+       "hidden-categories": "{{PLURAL:$1|Ezkutuko kategoria|Ezkutuko kategoriak}}",
        "hidden-category-category": "Kategoria ezkutuak",
        "category-subcat-count": "{{PLURAL:$2|Kategoria honek beste honako azpikategoria baino ez du.|Kategoria honek honako {{PLURAL:$1|azpikategoria du|$1 azpikategoriak ditu}}, guztira dauden $2tik.}}",
        "category-subcat-count-limited": "Kategoria honek {{PLURAL:$1|azpikategoria hau du|$1 azpikategoria hauek ditu}}.",
index 216969e..df0c8a7 100644 (file)
        "recentchanges-legend-plusminus": "(''±123'')",
        "recentchanges-submit": "Lister",
        "rcfilters-activefilters": "Filtres actifs",
+       "rcfilters-restore-default-filters": "Rétablir les filtres par défaut",
+       "rcfilters-clear-all-filters": "Effacer tous les filtres",
        "rcfilters-search-placeholder": "Modifications récentes de filtres (naviguer ou commencer à saisir)",
        "rcfilters-invalid-filter": "Filtre non valide",
+       "rcfilters-empty-filter": "Aucun filtre actif. Toutes les contributions sont affichées.",
        "rcfilters-filterlist-title": "Filtres",
        "rcfilters-filterlist-noresults": "Aucun filtre trouvé",
        "rcfilters-filtergroup-registration": "Inscription de l’utilisateur",
index e345969..1d22515 100644 (file)
        "statistics-users": "Prijavljeni [[Special:ListUsers|suradnici]]",
        "statistics-users-active": "Aktivni suradnici",
        "statistics-users-active-desc": "Suradnici koji su napravili neku od radnji u posljednjih {{PLURAL:$1|dan|$1 dana}}",
-       "pageswithprop": "Stranice sa osobinom stranice",
-       "pageswithprop-legend": "Stranice sa osobinom stranice",
+       "pageswithprop": "Stranice s određenim osobinama",
+       "pageswithprop-legend": "Stranice s određenim osobinama",
+       "pageswithprop-text": "Ovo je popis stranica koje koriste određene osobine stranica.",
        "pageswithprop-prop": "Ime osobine:",
        "pageswithprop-submit": "Idi",
        "doubleredirects": "Dvostruka preusmjeravanja",
        "booksources-search": "Traži",
        "booksources-text": "Ovdje je popis vanjskih poveznica na internetskim stranicama koje prodaju nove i rabljene knjige, ali mogu sadržavati i ostale podatke o knjigama koje tražite:",
        "booksources-invalid-isbn": "Čini se da dani ISBN nije valjan; provjerite greške kopirajući iz izvornika.",
+       "magiclink-tracking-rfc": "Stranice s čarobnim RFC poveznicama",
+       "magiclink-tracking-rfc-desc": "Ova stranica rabi čarobne RFC poveznice. Za njihovu migraciju vidi [https://www.mediawiki.org/wiki/Special:MyLanguage/Help:Magic_links mediawiki.org].",
+       "magiclink-tracking-pmid": "Stranice s čarobnim PMID poveznicama",
+       "magiclink-tracking-pmid-desc": "Ova stranica rabi čarobne PMID poveznice. Za njihovu migraciju vidi [https://www.mediawiki.org/wiki/Special:MyLanguage/Help:Magic_links mediawiki.org].",
        "magiclink-tracking-isbn": "Stranice s čarobnim ISBN poveznicama",
        "magiclink-tracking-isbn-desc": "Ova stranica rabi čarobne ISBN poveznice. Za njihovu migraciju vidi [https://www.mediawiki.org/wiki/Special:MyLanguage/Help:Magic_links mediawiki.org].",
        "specialloguserlabel": "Suradnik:",
        "listgrants-summary": "Slijedi popis dozvola s pridruženim pristupom suradničkim pravima. Suradnici mogu omogućiti aplikacijama uporabu svojih računa, ali s ograničenim ovlastima na temelju dozvola koje je suradnik dodijelio aplikaciji. Aplikacija koja djeluje u ime suradnika međutim ne može rabiti prava koje suradnik nema.\nMoguće su [[{{MediaWiki:Listgrouprights-helppage}}|dodatne informacije]] o pojedinim pravima.",
        "listgrants-grant": "Dozvola",
        "listgrants-rights": "Prava",
+       "trackingcategories": "Kategorije za praćenje",
+       "trackingcategories-msg": "Praćene kategorije",
+       "trackingcategories-name": "Naziv poruke",
+       "trackingcategories-desc": "Kriteriji za uključenje u kategoriju",
        "restricted-displaytitle-ignored": "Stranice sa zanemarenim naslovima za prikaz",
+       "restricted-displaytitle-ignored-desc": "Na stranici je zanemaren <code><nowiki>{{DISPLAYTITLE}}</nowiki></code> jer ne odgovara trenutačnom naslovu stranice.",
        "trackingcategories-nodesc": "Opis nije dostupan.",
+       "trackingcategories-disabled": "Kategorija onemogućena",
        "mailnologin": "Nema adrese pošiljatelja",
        "mailnologintext": "Morate biti [[Special:UserLogin|prijavljeni]]\ni imati valjanu adresu e-pošte u svojim [[Special:Preferences|postavkama]]\nda bi mogli slati poštu drugim suradnicima.",
        "emailuser": "Pošalji mu e-poruku",
index 40989e6..c9fc595 100644 (file)
        "resetpass-recycled": "Voluntez chanjar vua pasovorto ad ulo diferanta de vua aktuala pasovorto.",
        "resetpass-temp-emailed": "Vu eniris uzante provizora pasovorto.\nPor parkompletigar enirado, vu mustas krear nova pasovorto hike:",
        "resetpass-temp-password": "Provizora pasovorto:",
+       "passwordreset": "Sendez nova pasovorto per e-posto",
        "passwordreset-username": "Uzantonomo:",
        "passwordreset-invalidemail": "Ne-valida e-posto-adreso",
        "passwordreset-nodata": "Nek uzeronomo nek e-posto-adreso esis provizita",
        "accmailtext": "Hazarde genitita pasovorto por [[User talk:$1|$1]] sendesis ad $2.\n\nLa pasovorto por ica nova konto povas chanjesar che la ''[[Special:ChangePassword|chanjar pasovorto]]'' pagino pos on eniras.",
        "newarticle": "(nova)",
        "newarticletext": "Vu sequis ligilo a pagino qua ne existas ankore.\nPor krear ica pagino, voluntez startar skribar en la infra buxo.\n(regardez la [$1 helpo] por plusa informo).\nSe vu esas hike erore, kliktez sur la butono por retrovenar en vua navigilo.",
-       "noarticletext": "Prezente, ne esas texto en ica pagino.\nVu povas [[Special:Search/{{PAGENAME}}|serchar ica titulo]] en altra pagini,\n<span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} serchar en la relata registri],\no [{{fullurl:{{FULLPAGENAME}}|action=edit}} redaktar ica pagino]</span>.",
+       "noarticletext": "Til nun ne existas texto en ica pagino.\nVu povas [[Specala:Search/{{PAGENAME}}|serchar ica titulo]] en altra pagini,\n<span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} serchar en la relata registri],\no [{{fullurl:{{FULLPAGENAME}}|action=edit}} redaktar ica pagino]</span>.",
        "userpage-userdoesnotexist": "Uzeronomo \"$1\" no registragesis.\nVoluntez konfirmez se vu volas krear/redaktar ica pagino.",
        "userpage-userdoesnotexist-view": "Uzeronomo \"$1\" no registragesis.",
        "clearyourcache": "'''Atencez: Pos registragar, vu probable mustas renovigar la tempala-magazino di vua navigilo por vidar la chanji.'''\n'''Mozilla / Firefox / Safari:''' tenez ''Shift'' kliktante ''Reload'', o presez sive  ''Ctrl-F5'' sive ''Ctrl-R'' (''Command-R'' ye Mac);\n'''Konqueror''': kliktez ''Reload'' o presez ''F5'';\n'''Opera:''' vakuigez la tempala-magazino en ''Tools → Preferences'';\n'''Internet Explorer:''' tenez ''Ctrl'' kliktante ''Refresh,'' o presez ''Ctrl-F5''.",
        "mergehistory-reason": "Motivo:",
        "revertmerge": "Desmixar",
        "history-title": "Version-historio di \"$1\"",
+       "difference-title": "Diferi inter la revizi di $1",
        "lineno": "Lineo $1:",
        "compareselectedversions": "Komparar selektita versioni",
        "editundo": "des-facez",
+       "diff-multi-sameuser": "(ne montresas {{PLURAL:$1|1 meza revizo|$1 meza revizi}} facita da la sama uzero)",
        "searchresults": "Rezultaji dil sercho",
        "searchresults-title": "Sercho-rezultaji por \"$1\"",
        "titlematches": "Koincidi de titulo di artiklo",
        "searchprofile-articles-tooltip": "Serchez en $1",
        "searchprofile-images-tooltip": "Serchez arkivi",
        "search-result-size": "$1 ({{PLURAL:$2|1 vorto|$2 vorti}})",
-       "search-redirect": "(ridirektilo $1)",
+       "search-redirect": "(Ridirektita de $1)",
        "search-section": "(seciono $1)",
        "search-suggest": "Ka vu volis dicar: $1",
        "search-interwiki-caption": "Altra projekti",
        "search-interwiki-more": "(plusa)",
        "searchall": "omna",
        "showingresults": "Montrante infre {{PLURAL:$1|'''1''' rezulto|'''$1''' rezulti}}, qui komencas kun numero #'''$2'''.",
+       "search-nonefound": "Nula rezulto trovesis por lua serchado.",
        "powersearch-legend": "Avancita sercho",
        "powersearch-ns": "Serchez en nomari:",
        "powersearch-toggleall": "Omna",
        "action-upload": "adkargar ca arkivo",
        "action-browsearchive": "serchar pagini efacita",
        "nchanges": "$1 {{PLURAL:$1|chanjo|chanji}}",
+       "enhancedrc-history": "Versionaro",
        "recentchanges": "Recenta chanji",
        "recentchanges-legend": "Recenta chanji preferaji",
        "recentchanges-summary": "Regardez la maxim recenta chanji en Wiki per ica pagino.",
        "recentchanges-label-newpage": "Ca redaktajo kreis nova pagino",
        "recentchanges-label-minor": "Ica es mikra redaktajo",
        "recentchanges-label-bot": "Ta chanjo facita da bot",
+       "recentchanges-label-unpatrolled": "Ica modifiko ne patroliesas ankore.",
+       "recentchanges-label-plusminus": "La pagino modifikesis segun ica quanto di *bicoki",
        "recentchanges-legend-newpage": "$1 - nova pagino",
        "rcfilters-filter-userExpLevel-experienced-description": "Plu kam 30 dii di agemeso e 500 redakti.",
        "rcnotefrom": "Infre esas la lasta chanji depos '''$2''' (montrita til '''$1''').",
        "rclistfrom": "Montrar nova chanji startante de $3 $2",
        "rcshowhideminor": "$1 mikra redakti",
+       "rcshowhideminor-show": "Montrar",
+       "rcshowhideminor-hide": "Celar",
        "rcshowhidebots": "$1 roboti",
+       "rcshowhidebots-show": "Montrar",
+       "rcshowhidebots-hide": "Celar",
        "rcshowhideliu": "$1 enrejistrita uzeri",
+       "rcshowhideliu-hide": "Celar",
        "rcshowhideanons": "$1 anonima uzanti",
+       "rcshowhideanons-show": "Montrar",
+       "rcshowhideanons-hide": "Celar",
        "rcshowhidemine": "$1 mea redakti",
+       "rcshowhidemine-show": "Montrar",
+       "rcshowhidemine-hide": "Celar",
        "rclinks": "Montrar la lasta $1 chanji dum la lasta $2 dii<br />$3",
        "diff": "dif",
        "hist": "vers",
        "newpageletter": "N",
        "boteditletter": "r",
        "rc_categories_any": "Irga selektita",
+       "rc-change-size-new": "$1 {{PLURAL:$1|bicoko|bicoki}} pos la modifiki",
        "newsectionsummary": "/* $1 */ nova seciono",
        "rc-enhanced-expand": "Montrez detali",
        "rc-enhanced-hide": "Celar detali",
        "linkstoimage": "La {{PLURAL:$1|pagino|$1 pagini}} infre ligas a ca arkivo:",
        "nolinkstoimage": "Nula pagino ligas a ca pagino.",
        "sharedupload": "Ca arkivo esas de $1 e posible esas uzata da altra projekti.",
+       "sharedupload-desc-here": "Ca arkivo jacas en $1, e povas uzesar en altra projeti.\nLa deskriptado en lua [$2 pagino di deskriptado] montresas infre.",
        "uploadnewversion-linktext": "Adkargez nova versiono dil arkivo",
        "shared-repo-from": "ek $1",
+       "upload-disallowed-here": "Vu ne povas modifikar ica arkivo.",
        "filerevert-comment": "Motivo:",
        "filedelete": "Efacar $1",
        "filedelete-legend": "Efacar arkivo",
        "apisandbox-loading": "Charjas informo pri modulo « $1 » di API...",
        "booksources": "Fonti di libri",
        "booksources-search-legend": "Serchez librala fonti",
+       "booksources-search": "Serchar",
        "specialloguserlabel": "Agero:",
        "speciallogtitlelabel": "Skopo (titulo od {{ns:user}}:uzernomo por uzero):",
        "log": "Registrari",
        "deletereason-dropdown": "*Ordinara motivi por efacado\n** \"Spam\" nedezirata mesaji\n** Vandalismo\n** Kopiyuro Violaco\n** Demandita da autoro\n** Nefuncionanta ligilo",
        "rollback": "Retrorulez redakti",
        "rollbacklink": "retrorulez",
+       "rollbacklinkcount": "nuligar $1 {{PLURAL:$1|modifiko|modifiki}}",
        "rollbackfailed": "Retrorular ne sucesis",
        "cantrollback": "Ne esas posibla retrorular. La lasta kontributanto esas la nura autoro di ica pagino.",
        "alreadyrolled": "Vu ne povas retrorular la lasta chanjo di [[:$1]] da [[User:$2|$2]] ([[User talk:$2|Diskutez]]{{int:pipe-separator}}[[Special:Contributions/$2|{{int:contribslink}}]]);\nulu pluse ja redaktis o retrorulis ica pagino.\n\nLa lasta chanjo a la pagino esis da [[User:$3|$3]] ([[User talk:$3|Diskutez]]{{int:pipe-separator}}[[Special:Contributions/$3|{{int:contribslink}}]]).",
        "contributions": "Kontributadi dil {{GENDER:$1|uzero}}",
        "contributions-title": "Uzero-kontributadi di $1",
        "mycontris": "Kontributadi",
+       "anoncontribs": "Kontributadi",
        "contribsub2": "Pro $1 ($2)",
        "nocontribs": "Ne trovesis chanji qui fitez ita kriterii.",
        "uctop": "(aktuala)",
        "tooltip-pt-mycontris": "Listo di {{GENDER:|vua}} kontributaji",
        "tooltip-pt-login": "Vu darfas enirar uzante vua pas-vorto, ma lo ne esas preskriptata.",
        "tooltip-pt-logout": "Ekirar",
+       "tooltip-pt-createaccount": "Vu stimulesas a krear konto e facar \"log in\". Tamen, to ne esas obliganta",
        "tooltip-ca-talk": "Diskuto pri la pagino di kontenajo",
        "tooltip-ca-edit": "Redaktar ita pagino",
        "tooltip-ca-addsection": "Komencar nova seciono",
        "others": "altra",
        "siteusers": "{{PLURAL:$2|{{GENDER:$1|uzero}}|uzeri}} $1 di {{SITENAME}}",
        "spamprotectiontitle": "Filtrilo kontre spamo",
+       "simpleantispam-label": "Surveyo kontre \"spam\".\n<strong>NE SKRIBEZ</strong> hike!",
        "pageinfo-toolboxlink": "Informo di ca pagino",
        "previousdiff": "← Plu anciena versiono",
        "nextdiff": "Plu recenta versiono →",
        "widthheightpage": "$1 × $2, $3 {{PLURAL:$3|pagino|pagini}}",
        "file-nohires": "Ne existas grandeso plu granda.",
+       "svg-long-desc": "arkivo SVG, nominale $1 x $2 \"pixels\", kun $3",
        "show-big-image": "Arkivo originala",
+       "show-big-image-size": "$1 x $2 pixels",
        "newimages": "Galerio di nova arkivi",
        "imagelisttext": "Infre esas listo di '''$1''' {{PLURAL:$1|arkivo|arkivi}} rangizita $2.",
        "newimages-legend": "Filtrilo",
        "ilsubmit": "Serchar",
        "bydate": "per dato",
        "metadata": "Metadonaji",
+       "metadata-help": "Ca arkivo kontenas plusa informo, probable furnisita per la kamero elektronikala o per la \"scanner\" uzata por krear o kopiar l'imajo.\nSe l'arkivo modifikesos de lua originala stando, kelka detali povos ne reprezentar exakte l'arkivo modifikata.",
+       "metadata-fields": "Image metadata fields listed in this message will be included on image page display when the metadata table is collapsed.\nOthers will be hidden by default.\n* make\n* model\n* datetimeoriginal\n* exposuretime\n* fnumber\n* isospeedratings\n* focallength\n* artist\n* copyright\n* imagedescription\n* gpslatitude\n* gpslongitude\n* gpsaltitude",
        "exif-imagewidth": "Larjeso",
        "exif-imagelength": "Alteso",
+       "exif-orientation": "Orientizo",
+       "exif-xresolution": "Horizontala distingivo",
+       "exif-yresolution": "Vertikala distingivo",
+       "exif-datetime": "Dio e horo di la modifiko dil arkivo",
+       "exif-make": "Fabrikanto di la fotografilo",
+       "exif-model": "Fotografilo uzita",
+       "exif-software": "*Komputeroprogramo uzata",
        "exif-artist": "Autoro",
+       "exif-exifversion": "versiono Exif",
+       "exif-datetimeoriginal": "Dio e horo di produktado di la datumaro",
+       "exif-datetimedigitized": "Dio e horo di la kopio kun \"scanner\"",
        "exif-exposuretime-format": "$1 sek ($2)",
        "exif-gpslatitude": "Latitudo",
        "exif-gpslongitude": "Longitudo",
        "watchlisttools-view": "Vidar relatanta chanji",
        "watchlisttools-edit": "Vidar e redaktar surveyo-listo",
        "watchlisttools-raw": "Redaktar texto di surveyo-listo",
+       "signature": "[[{{ns:user}}:$1|$2]] ([[{{ns:user_talk}}:$1|diskuto]])",
        "version": "Versiono",
        "version-specialpages": "Specala pagini",
        "version-other": "Altra",
        "specialpages-group-redirects": "Specala pagini di ridirektili",
        "blankpage": "Pagino sen-skribura",
        "tag-filter-submit": "Filtrez",
+       "tag-list-wrapper": "([[Special:Tags|{{PLURAL:$1|Etikedo|Etikedi}}]]: $2)",
        "tags-edit": "redaktar",
        "tags-hitcount": "$1 {{PLURAL:$1|chanjo|chanji}}",
        "htmlform-reset": "Desfacar chanji",
        "htmlform-selectorother-other": "Altra",
        "htmlform-cloner-create": "Adjuntar plue",
+       "logentry-move-move": "$1 {{GENDER:$2|movis}} la pagino $3 a $4",
+       "logentry-newusers-create": "La konto dil uzero $1 kreesis.",
+       "logentry-upload-upload": "$1 {{GENDER:$2|uploaded}} $3",
        "rightsnone": "(nula)",
        "revdelete-summary": "redakto-rezumo",
        "searchsuggest-search": "Serchez en {{SITENAME}}",
index 2cd84d3..ce3d5e7 100644 (file)
        "recentchanges-legend-plusminus": "(''±123'')",
        "recentchanges-submit": "Mostra",
        "rcfilters-activefilters": "Filtri attivi",
+       "rcfilters-restore-default-filters": "Ripristina i filtri predefiniti",
+       "rcfilters-clear-all-filters": "Pulisci tutti i filtri",
        "rcfilters-search-placeholder": "Filtra le ultime modifiche (naviga o inizia a digitare)",
        "rcfilters-invalid-filter": "Filtro non valido",
+       "rcfilters-empty-filter": "Nessun filtro attivo. Sono mostrati tutti i contributi.",
        "rcfilters-filterlist-title": "Filtri",
        "rcfilters-filterlist-noresults": "Nessun filtro trovato",
        "rcfilters-filtergroup-registration": "Registrazione utente",
index a7ee19c..3f45d64 100644 (file)
        "recentchanges-legend-plusminus": "(<em>±123</em>)",
        "recentchanges-submit": "보기",
        "rcfilters-activefilters": "사용 중인 필터",
+       "rcfilters-restore-default-filters": "기본 필터 복구",
+       "rcfilters-clear-all-filters": "필터 모두 지우기",
        "rcfilters-search-placeholder": "필터 최근 바뀜 (찾아보거나 입력을 시작하십시오)",
        "rcfilters-invalid-filter": "유효하지 않은 필터",
+       "rcfilters-empty-filter": "활발한 필터 없음. 모든 기여 내역을 보여줍니다.",
        "rcfilters-filterlist-title": "필터",
        "rcfilters-filterlist-noresults": "필터를 찾을 수 없습니다",
        "rcfilters-filtergroup-registration": "사용자 등록",
+       "rcfilters-filter-registered-label": "등록됨",
+       "rcfilters-filter-registered-description": "로그인된 편집자.",
+       "rcfilters-filter-unregistered-label": "등록 안됨",
+       "rcfilters-filter-unregistered-description": "로그인 하지 않은 편집자.",
        "rcfilters-filtergroup-authorship": "원작자 편집",
        "rcfilters-filter-editsbyself-label": "자신의 편집",
        "rcfilters-filter-editsbyself-description": "당신의 편집.",
        "rcfilters-filter-editsbyother-label": "다른 사용자의 편집",
-       "rcfilters-filter-editsbyother-description": "다른 사용자에 의한 편집. (당신의 편집이 아님)",
+       "rcfilters-filter-editsbyother-description": "다른 사용자에 의한 편집 (당신의 편집이 아님).",
        "rcfilters-filtergroup-userExpLevel": "경험 수준 (등록된 사용자 전용)",
        "rcfilters-filter-userExpLevel-newcomer-label": "신규 사용자",
-       "rcfilters-filter-userExpLevel-newcomer-description": "신규 편집자: 10개 미만의 편집 및 4일 미만의 활동.",
+       "rcfilters-filter-userExpLevel-newcomer-description": "편집 10회 미만의 편집 및 4일 미만의 활동.",
        "rcfilters-filter-userExpLevel-learner-label": "학습자",
-       "rcfilters-filter-userExpLevel-learner-description": "'신규 사용자' 보다 활동일 및 편집 수가 더 많지만 '능숙한 사용자' 보다는 적습니다.",
+       "rcfilters-filter-userExpLevel-learner-description": "\"신규 사용자\" 보다 활동일 및 편집 수가 더 많지만 \"능숙한 사용자\" 보다는 적습니다.",
        "rcfilters-filter-userExpLevel-experienced-label": "능숙한 사용자",
        "rcfilters-filter-userExpLevel-experienced-description": "30일 이상의 활동 및 500개 이상의 편집.",
+       "rcfilters-filtergroup-automated": "자동으로 된 기여",
        "rcfilters-filter-bots-label": "봇",
+       "rcfilters-filter-bots-description": "자동 도구를 이용한 편집.",
        "rcfilters-filter-humans-label": "사람 (봇이 아님)",
+       "rcfilters-filter-humans-description": "수동으로 한 편집.",
        "rcfilters-filter-minor-label": "사소한 편집",
        "rcfilters-filter-major-label": "사소하지 않은 편집",
+       "rcfilters-filter-major-description": "사소한 편집으로 표시되지 않은 편집.",
+       "rcfilters-filtergroup-changetype": "차이 종류",
        "rcfilters-filter-pageedits-label": "문서 편집",
+       "rcfilters-filter-newpages-label": "문서 생성",
+       "rcfilters-filter-newpages-description": "새 문서를 만드는 편집.",
+       "rcfilters-filter-categorization-label": "분류 차이",
        "rcnotefrom": "아래는 <strong>$3, $4</strong>부터 시작하는 {{PLURAL:$5|바뀜이 있습니다}}. (최대 <strong>$1</strong>개가 표시됨)",
        "rclistfrom": "$3 $2부터 시작하는 새로 바뀐 문서 보기",
        "rcshowhideminor": "사소한 편집 $1",
index 2f0a797..1d786c2 100644 (file)
@@ -7,7 +7,8 @@
                        "Reedy",
                        "Urhixidur",
                        "아라",
-                       "Katxis"
+                       "Katxis",
+                       "Chabi"
                ]
        },
        "tog-underline": "Sulinia lias:",
        "disclaimers": "Negas de respondablia",
        "disclaimerpage": "Project:Nega jeneral de respondablia",
        "edithelp": "Aida con edita",
+       "helppage-top-gethelp": "Aida",
        "mainpage": "Paje Prima",
        "mainpage-description": "Paje Prima",
        "policy-url": "Project:Politica",
        "toc": "Contenida",
        "showtoc": "mostra",
        "hidetoc": "asconde",
+       "collapsible-collapse": "Colasa",
+       "collapsible-expand": "Estende",
+       "confirmable-confirm": "Esce {{GENDER:$1|tu}} es serta?",
+       "confirmable-yes": "Si",
+       "confirmable-no": "No",
        "viewdeleted": "Vide $1?",
        "feedlinks": "Flue:",
        "site-rss-feed": "$1 RSS Flue",
        "badtitletext": "La titulo de la paje tu ia desira ia es nonlegal, es vacua, o es un titulo intervici o interlingual no liada coreta. Es posable ce es un o plu simboles ce no pote es usada en titulos.",
        "viewsource": "Vide la orijin",
        "viewsourcetext": "Tu pote vide e copia la orijin de esta paje:",
+       "mycustomcssprotected": "Tu no ave permete per edita esta paje CSS.",
+       "mycustomjsprotected": "Tu no ave permete per edita esta paje JavaScript.",
+       "myprivateinfoprotected": "Tu no ave permete per edita tua informa privata.",
+       "mypreferencesprotected": "Tu no ave permete per edita tua preferes.",
+       "ns-specialprotected": "La pajes spesial no pote es editada.",
+       "welcomeuser": "Bonveni, $1!",
        "yourname": "Nom de usor:",
        "userlogin-yourname": "Nom de usor",
        "userlogin-yourname-ph": "Entra tua nom de usor",
        "gotaccountlink": "Sinia per entra",
        "userlogin-resetpassword-link": "Tu ia oblida tua sinia secreta?",
        "userlogin-helplink2": "Aida me per identifia me",
+       "createacct-emailrequired": "Adirije de e-posta",
        "createacct-emailoptional": "Adirije de e-posta (elejable)",
        "createacct-email-ph": "Entra tua adirije de e-posta",
+       "createacct-another-email-ph": "Entra tua adirije de e-posta",
+       "createaccountreason": "Razona:",
+       "createacct-reason": "Razona:",
        "createacct-submit": "Crea tua conta",
+       "createacct-another-submit": "Crea un conta",
        "createacct-benefit-heading": "{{SITENAME}} es fabricada par persones como tu.",
        "createacct-benefit-body1": "{{PLURAL:$1|edita|editas}}",
        "createacct-benefit-body2": "{{PLURAL:$1|paje|pajes}}",
        "createacct-benefit-body3": "{{PLURAL:$1|contribuor|contribuores}}",
        "loginerror": "Era de entra",
-       "loginsuccesstitle": "Entra susedente",
+       "loginsuccesstitle": "Tu ia entra",
        "loginsuccess": "'''Tu ia entrada aora a {{SITENAME}} como \"$1\".'''",
-       "nosuchuser": "Es no usor con la nom \"$1\".\nEsamina la spele, o [[Special:CreateAccount|crea un conta nova]].",
+       "nosuchuser": "On no ave un usor con la nom \"$1\".\nOn distingui entre leteras major e minor per nomes de usores.\nEsamina la spele, o [[Special:CreateAccount|crea un conta nova]].",
        "nosuchusershort": "Es no usor con esta nom \"$1\". Esamina la spele.",
        "nouserspecified": "Tu debe indica un nom de usor.",
        "wrongpassword": "La sinia de entra no es coreta. Per favore, atenta ancora.",
        "wrongpasswordempty": "La sinia de entra es vacua. Per favore, atenta ancora.",
-       "passwordtooshort": "Tu sinia secreta no es legal o es tro corta.\nEl debe ave a min {{PLURAL:$1|1 simbol|$1 simboles}} e debe difere de tu nom de usor.",
-       "mailmypassword": "Envia la sinia secreta nova par eposta",
+       "passwordtooshort": "Sinias secreta debe ave minima {{PLURAL:$1|1 simbol|$1 simboles}}.",
+       "passwordtoolong": "Sinias secreta no pote ave plu ca {{PLURAL:$1|1 simbol|$1 simboles}}.",
+       "passwordtoopopular": "Sinias secreta comun debe no es usada. Per favore, eleje un sinia plu unica.",
+       "mailmypassword": "Cambia tua sinia secreta",
        "passwordremindertitle": "Sinia secreta temporer nova per {{SITENAME}}",
-       "passwordremindertext": "Algun (tu, probable, de adirije IP $1)\nia demanda ce nos envia a tu un sinia secreta nova per {{SITENAME}} ($4).\nLa sinia secreta per usor \"$2\" es aora \"$3\".\nTu debe sinia per entra e cambia tu sinia secreta aora.\n\nSi algun otra ce tu ia envia esta demanda a nos, o si tu ia recorda tu sinia secreta e no vole cambia el aora, tu pote iniora esta mesaje e continua usa tu sinia secreta vea.",
+       "passwordremindertext": "Algun (tu, probable, de adirije IP $1)\nia demanda un sinia secreta nova per {{SITENAME}} ($4).\nLa sinia secreta tempora per usor \"$2\" es aora \"$3\". Si esta ia es tua intende, tu debe identifia tu denova per entra e eleje tua sinia nova aora.\nTua sinia tempora va desvalidi en {{PLURAL:$5|un dia|$5 dias}}.\n\nSi algun otra ca tu ia envia esta demanda a nos, o si tu ia recorda tua sinia secreta e no vole cambia lo aora, tu pote iniora esta mesaje e continua usa tua sinia secreta vea.",
        "noemail": "No es un adirije de eposta per usor \"$1\".",
        "passwordsent": "Un sinia secreta ia es enviada a la adirije de eposta per \"$1\".\nPer favore, sinia per entra ancora pos tu ia reseta el.",
-       "eauthentsent": "Un eposta de serti ia es enviada a la adirije de eposta proposada.\nAnte alga otra eposta es enviada a la conta, tu va nesesa segue la instruis en la eposta, per serti ce la conta es vera de tu.",
+       "eauthentsent": "Un eposta de serti ia es enviada a la adirije de eposta spesifada.\nAnte cualce otra epostas es enviada a tua conta, tu va nesesa segue la instruis en la eposta, per serti ce la conta es vera la tua.",
        "emailconfirmlink": "Aproba tu adirije de eposta",
+       "accountcreated": "Conta es creada",
        "loginlanguagelabel": "Lingua: $1",
        "pt-login": "Identifia se",
        "pt-login-button": "Identifia tua",
        "resetpass-submit-loggedin": "Cambia la sinia secreta",
        "resetpass-temp-password": "Sinia secreta tempora:",
        "passwordreset": "Reinisia sinia secreta",
+       "passwordreset-username": "Nom de usor:",
+       "passwordreset-domain": "Domina:",
+       "passwordreset-email": "Adirije de e-posta",
+       "passwordreset-invalidemail": "Adirije de e-posta no es valida",
+       "changeemail-submit": "Cambia e-posta",
        "bold_sample": "Testo en leteras forte",
        "bold_tip": "Testo en leteras forte",
        "italic_sample": "Testo en leteras italica",
        "sig_tip": "Tu sinia con la primi de la ora",
        "hr_tip": "Linia orizonal (usa nonfrecuente)",
        "summary": "Soma:",
-       "subject": "Sujeto/titulo:",
+       "subject": "Sujeto:",
        "minoredit": "Esta es un cambia minor",
        "watchthis": "Oserva esta paje",
        "savearticle": "Fisa paje",
+       "publishpage": "Publici paje",
+       "publishchanges": "Publica la cambias",
        "preview": "Previde",
        "showpreview": "Mostra previde",
        "showdiff": "Mostra diferes",
        "summary-preview": "Previde soma:",
        "blockedtitle": "Usor es impedida",
        "blockedtext": "'''Tu nom de usor o adirije de IP ia es impedida.'''\n\nLa impedi ia es fada par $1.\nLa razon donada es ''$2''.\n\n* Comensa de impedi: $8\n* Fini de impedi: $6\n* Ci algun intende impedi: $7\n\nTu pote contata $1 o un otra [[{{MediaWiki:Grouppage-sysop}}|dirijor]] per discute esta impedi.\nTu no pote usa la 'envia un eposta a esta usor' sin un adirije de eposta legal es indicada en tu\n[[Special:Preferences|preferis de conta]] e tu no es impedida de usa el.\nTu adirije de IP es aora $3, e la identia de la impedi es #$5.\nPer favore inclui tota esta detales en tu demandas.",
+       "loginreqtitle": "Entra de identia nesesada",
        "loginreqlink": "Identifia se",
        "newarticle": "(Nova)",
        "newarticletext": "Tu ia segue un lia a un paje ce no esista ja.\nPer crea la paje, comensa scrive en la caxa a su\n(vide la [$1 paje de aida] per plu).\nSi tu es asi par era, clica a la boton '''retro''' de tu surfador.",
        "hiddencategories": "Esta paje es un membro de {{PLURAL:$1|1 categoria ascondeda|$1 categorias ascondeda}}:",
        "nocreatetext": "{{SITENAME}} ave un restringe a la capas per crea pajes nova.\nTu pote vade a retro e edita un paje esistente, o  [[Special:UserLogin|sinia per entra o crea un conta]].",
        "permissionserrorstext-withaction": "Tua no es permeteda per $2, per la {{PLURAL:$1|razona|razonas}} seguente:",
-       "recreate-moveddeleted-warn": "'''Avisa: Tu es recrea un paje ce ia es sutraed en la pasada.'''\nTu debe pensa ce es bon continua edita esta paje.\nLa arcivo de sutraes per esta paje es asi per conveni:",
+       "recreate-moveddeleted-warn": "<strong>Avisa: Tu es recreante un paje cual ia es sutraeda a ante.</strong>\nTu debe pensa si la continua de edita de esta paje conveni.\nLa arcivo de sutraes e moves per esta paje es asi per tua conveni:",
        "moveddeleted-notice": "Esta paje ia es sutraeda.\nLa arcivo de sutraes e moves per la paje es furnida a su per refere.",
        "viewpagelogs": "Vide la arcivo de esta paje",
        "currentrev": "Cambia presente",
        "page_last": "final",
        "histlegend": "Diferente eleje: Marca la caxas de radio de esta varias per compare e clica entra o la boton a la funda.<br />\n(presente) = difere de la varia presente,\n(presedente) = difere con varia presedente, M = edita minor.",
        "history-fieldset-title": "Surfa istoria",
-       "histfirst": "Prima",
-       "histlast": "Ultima",
+       "histfirst": "La plu vea",
+       "histlast": "La plu nova",
        "historysize": "({{PLURAL:$1|1 otuple|$1 otuples}})",
        "historyempty": "(vacua)",
        "history-feed-title": "Istoria de revises",
        "history-feed-item-nocomment": "$1 a $2",
        "rev-delundel": "mostra/asconde",
+       "rev-showdeleted": "mostra",
+       "revdelete-show-file-submit": "Si",
+       "revdelete-radio-set": "Ascondeda",
+       "revdelete-radio-unset": "Vidable",
+       "pagehist": "Istoria de paje",
+       "deletedhist": "Istoria sutraeda",
        "history-title": "Istoria de cambias de \"$1\"",
        "difference-title": "Difere entre revisas de \"$1\"",
        "lineno": "Linia $1:",
        "searchall": "tota",
        "search-showingresults": "{{PLURAL:$4|Resulta <strong>$1</strong> de <strong>$3</strong>|Resultas <strong>$1 - $2</strong> de <strong>$3</strong>}}",
        "search-nonefound": "On ave no resultas cual conforma con la demanda.",
+       "powersearch-toggleall": "Tota",
+       "powersearch-togglenone": "Zero",
        "preferences": "Preferis",
        "mypreferences": "Preferis",
        "skin-preview": "Previde",
        "timezoneregion-pacific": "Mar Pasifica",
        "prefs-files": "Fixes",
        "youremail": "Eposta:",
-       "username": "Nom de usor:",
-       "prefs-memberingroups": "Membro de la {{PLURAL:$1|grupo|grupos}}:",
+       "username": "{{GENDER:$1|Nom de usor}}:",
+       "prefs-memberingroups": "{{GENDER:$2|Membro}} de {{PLURAL:$1|grupo|grupos}}:",
        "yourrealname": "Nom vera:",
        "yourlanguage": "Lingua:",
        "yournick": "Suscrive:",
-       "yourgender": "Seso:",
-       "gender-male": "Mas",
-       "gender-female": "Fema",
+       "yourgender": "Como tu prefere ce tu es descriveda?",
+       "gender-male": "El edita pajes de wiki",
+       "gender-female": "El edita pajes de wiki",
        "email": "Eposta",
-       "prefs-help-realname": "Tu nom vera no es obligada, ma si tu vole dona tu nom vera, el va es usada per onora tu per tu labora.",
+       "prefs-help-realname": "Tu nom vera no es obligada, ma si tu vole dona tu nom vera, el va es usada per onora tu per tu labora.\n\nTu no debe entra tua nom vera. Ma si tu entra tua noma vera, lo pote es usada per atribui tua laboras a tu.",
        "prefs-signature": "Suscrive",
        "userrights": "Dirije de la diretos de usores",
        "saveusergroups": "Fisa la grupo de usores",
        "group-user": "Usores",
        "group-sysop": "Dirijores",
        "group-all": "(tota)",
-       "group-user-member": "Usor",
+       "group-user-member": "{{GENDER:$1|usor}}",
        "grouppage-user": "{{ns:project}}:Usores",
        "grouppage-sysop": "{{ns:project}}:Dirijores",
        "right-writeapi": "Usa de la API de scrive",
        "minoreditletter": "m",
        "newpageletter": "N",
        "boteditletter": "b",
-       "rc_categories_any": "Cualce",
+       "rc_categories_any": "Cualce de la elejeda",
        "rc-change-size-new": "$1 {{PLURAL:$1|bait|baites}}  pos cambia",
        "rc-enhanced-expand": "Mostra detalias",
        "rc-enhanced-hide": "Asconde detalias",
        "wantedpages": "Pajes desirada",
        "mostlinked": "Pajes la plu liada",
        "mostlinkedcategories": "Categorias a ce es la plu lias",
-       "mostlinkedtemplates": "Modeles a ce es la plu lias",
+       "mostlinkedtemplates": "Pajes la plu liada",
        "mostcategories": "Pajes con la plu categorias",
        "mostimages": "Fixes a ce es la plu lias",
        "mostrevisions": "Pajes con la plu revisas",
        "longpages": "Pajes longa",
        "deadendpages": "Pajes sin sorti",
        "protectedpages": "Pajes protejeda",
+       "protectedpages-page": "Paje",
+       "protectedpages-expiry": "Desvalidi",
        "listusers": "Lista de usores",
        "newpages": "Pajes nova",
        "ancientpages": "Pajes la plu vea",
        "listgrouprights-group": "Grupo",
        "listgrouprights-members": "(lista de membros)",
        "emailuser": "Envia un eposta a esta usor",
-       "emailfrom": "De",
-       "emailto": "Per",
-       "watchlist": "Pajes oservada",
+       "emailfrom": "De:",
+       "emailto": "A:",
+       "emailsubject": "Sujeto:",
+       "emailmessage": "Mesaje:",
+       "emailsend": "Envia",
+       "emailsent": "E-posta ia es enviada",
+       "watchlist": "Lista de pajes oservada",
        "mywatchlist": "Lista de pajes oservada",
+       "watchlistfor2": "Per $1 $2",
        "nowatchlist": "Tu ave no cosas en tu lista oservada",
        "addedwatchtext": "La paje \"[[:$1]]\" ia es juntada a tu [[Special:Watchlist|lista de pajes oservada]].\nCambias future a esta paje e se paje de discutes va es listada ala, e la paje va apera en leteras '''forte''' en la [[Special:RecentChanges|lista de cambias resente]] per es plu fasil oservada.\n\nSi tu vole sutrae la paje de tu lista de pajes oservada en la futur, clica a \"no oserva\" en la bara a la lado.",
        "removedwatchtext": "La paje \"[[:$1]]\" ia es sutraeda de [[Special:Watchlist|tu lista de pajes oservada]].",
        "move-page-legend": "Move paje",
        "movepagetext": "Usa la forma a su va cambia la nom de un paje, e va move tota se istoria a la nom nova.\nLa titulo vea va deveni un paje de redirije a la titulo nova.\nLias a la titulo de la paje vea no va es cambiada;\nTu debe vide serta ce es redirijes duple o rompeda.\nTu es respondable per es serta ce la lias va continua vade a la locas intendeda.\n\nNota ce la paje '''no''' va es moveda si es ja un paje a la titulo nova, sin el es vacua o un redirije e no ave un istoria de editas presedente.\nEsta sinifia ce tu pote cambia la nom de un paje a la loca presedente si tu era, e tu no pote scrive supra un paje ce esiste ja.\n\n'''AVISA!'''\nEsta pote es un cambia dramos e nonespetada per un paje poplal;\nper favore, es serta ce tu comprende la resulta de esta ata ante tu continua.",
        "movepagetalktext": "La paje de discuta de esta paje va es moveda automatica con el '''eseta si:'''\n*Un paje de discuta ce no es vacua esiste ja su la nom nova, o\n*Tu cambia la indica en la caxa su.\n\nEn esta casos, tu va nesesa move o fusa la paje per mano, si desirada.",
-       "newtitle": "A titulo nova:",
+       "newtitle": "Titulo nova:",
        "move-watch": "Oserva esta paje",
        "movepagebtn": "Move paje",
        "pagemovedsub": "La move ia susede",
index 75ed4c2..3e1e0dc 100644 (file)
        "recentchanges-legend-plusminus": "(''±123'')",
        "recentchanges-submit": "Прикажи",
        "rcfilters-activefilters": "Активни филтри",
+       "rcfilters-restore-default-filters": "Поврати основни филтри",
+       "rcfilters-clear-all-filters": "Тргни ги сите филтри",
        "rcfilters-search-placeholder": "Филтрирај скорешни промени (прелстајте или почнете да пишувате)",
        "rcfilters-invalid-filter": "Неважечки филтер",
+       "rcfilters-empty-filter": "Нема активни филтри. Прикажани се сите придонеси.",
        "rcfilters-filterlist-title": "Филтри",
        "rcfilters-filterlist-noresults": "Не пронајдов ниеден филтер",
        "rcfilters-filtergroup-registration": "Регистрација на корисници",
index 50abf54..802933e 100644 (file)
        "revdelete-unrestricted": "အက်ဒမင်များအတွက် ကန့်သတ်ချက်များကို ဖယ်ရှားရန်",
        "logentry-suppress-block": "{{GENDER:$4|$3}} အား $5 ကြာအောင် $1 က {{GENDER:$2|ပိတ်ပင်ခဲ့သည်}} $6",
        "logentry-move-move": "$3 စာမျက်နှာကို $4 သို့ $1က {{GENDER:$2|ရွှေ့ခဲ့သည်}}",
-       "logentry-move-move-noredirect": "$3 á\80\99á\80¾ $4 á\80\9eá\80­á\80¯á\80· á\80\85á\80¬á\80\99á\80»á\80\80á\80ºá\80\94á\80¾á\80¬á\80\80á\80­á\80¯ á\80\95á\80¼á\80\94á\80ºá\80\8aá\80½á\80¾á\80\94á\80ºá\80¸á\80\81á\80»á\80\94á\80ºá\80\99á\80\91á\80¬á\80¸á\80\95ဲ $1 {{GENDER:$2|က ရွှေ့ခဲ့သည်}}",
+       "logentry-move-move-noredirect": "$3 á\80\99á\80¾ $4 á\80\9eá\80­á\80¯á\80· á\80\85á\80¬á\80\99á\80»á\80\80á\80ºá\80\94á\80¾á\80¬á\80\80á\80­á\80¯ á\80\95á\80¼á\80\94á\80ºá\80\8aá\80½á\80¾á\80\94á\80ºá\80¸á\80\81á\80»á\80\94á\80ºá\80\99á\80\91á\80¬á\80¸á\80\98ဲ $1 {{GENDER:$2|က ရွှေ့ခဲ့သည်}}",
        "logentry-move-move_redir": "$3 စာမျက်နှာကို $4 သို့ ပြန်ညွှန်းပေါ်ထပ်၍ $1 က {{GENDER:$2|ရွှေ့ခဲ့သည်}}",
+       "logentry-move-move_redir-noredirect": "$3 မှ $4 သို့ ပြန်ညွှန်ပေါ်ထပ်အုပ်ကာ ပြန်ညွှန်းချန်မထားဘဲ $1 က {{GENDER:$2|ရွှေ့ခဲ့သည်}}",
        "logentry-newusers-create": "အသုံးပြုသူအကောင့် $1 ကို {{GENDER:$2|ဖန်တီးခဲ့သည်}}",
        "logentry-newusers-autocreate": "အသုံးပြုသူအကောင့် $1 ကို အလိုအလျောက် {{GENDER:$2|ဖန်တီးခဲ့သည်}}",
        "logentry-upload-upload": "$1 သည် $3 ကို {{GENDER:$2|upload တင်ခဲ့သည်}}",
index 1e71b88..8c2eef7 100644 (file)
        "recentchanges-legend-plusminus": "{{optional}}\nA plus/minus sign with a number for the legend.",
        "recentchanges-submit": "Label for submit button in [[Special:RecentChanges]]\n{{Identical|Show}}",
        "rcfilters-activefilters": "Title for the filters selection showing the active filters.",
+       "rcfilters-restore-default-filters": "Label for the button that resets filters to defaults",
+       "rcfilters-clear-all-filters": "Title for the button that clears all filters",
        "rcfilters-search-placeholder": "Placeholder for the filter search input.",
        "rcfilters-invalid-filter": "A label for an invalid filter.",
+       "rcfilters-empty-filter": "Placeholder for the filter list when no filters were chosen.",
        "rcfilters-filterlist-title": "Title for the filters list.\n{{Identical|Filter}}",
        "rcfilters-filterlist-noresults": "Message showing no results found for searching a filter.",
        "rcfilters-filtergroup-registration": "Title for the filter group for editor registration type.",
        "rcfilters-filter-bots-label": "Label for the filter for showing edits made by automated tools.\n{{Identical|Bot}}",
        "rcfilters-filter-bots-description": "Description for the filter for showing edits made by automated tools.",
        "rcfilters-filter-humans-label": "Label for the filter for showing edits made by human editors.",
-       "rcfilters-filter-humans-description": " Description for the filter for showing edits made by human editors.",
+       "rcfilters-filter-humans-description": "Description for the filter for showing edits made by human editors.",
        "rcfilters-filtergroup-significance": "Title for the filter group for edit significance.\n{{Identical|Significance}}",
        "rcfilters-filter-minor-label": "Label for the filter for showing edits marked as minor.",
        "rcfilters-filter-minor-description": "Description for the filter for showing edits marked as minor.",
index ce1e7e2..6011dfb 100644 (file)
        "recentchanges-legend-plusminus": "(''±123'')",
        "recentchanges-submit": "Показать",
        "rcfilters-activefilters": "Активные фильтры",
+       "rcfilters-restore-default-filters": "Восстановить фильтры по умолчанию",
+       "rcfilters-clear-all-filters": "Очистить все фильтры",
        "rcfilters-search-placeholder": "Последние изменения фильтров (просмотрите или начните вводить)",
        "rcfilters-invalid-filter": "Недопустимый фильтр",
+       "rcfilters-empty-filter": "Нет активных фильтров. Показываются все правки.",
        "rcfilters-filterlist-title": "Фильтры",
        "rcfilters-filterlist-noresults": "Фильтры не найдены",
        "rcfilters-filtergroup-registration": "Регистрация участников",
index 259bbe2..389398d 100644 (file)
        "badsig": "Loš sirovi potpis.\nProvjerite HTML tagove.",
        "badsiglength": "Vaš potpis je predug.\nMora biti manji od $1 {{PLURAL:$1|znaka|znaka|znakova}}.",
        "yourgender": "Kako želite da se predstavite?",
-       "gender-unknown": "Kad vas spominje, softver će pokušati koristiti srednji rod kad god je to moguće",
+       "gender-unknown": "Kad Vas spominje, softver će pokušati izbjegavati rod kad god je to moguće",
        "gender-male": "On uređuje wiki stranice",
        "gender-female": "Ona uređuje wiki stranice",
        "prefs-help-gender": "Postavljanje ove preferencije nije obavezno.\nSoftver koristi ovu vrijednost kako bi vam se obratio i spomenuo vas drugima koristeći vaš gramatički rod.\nOva informacija će biti javna.",
index bf31c91..fae2cb6 100644 (file)
        "recentchanges-legend-newpage": "{{int:recentchanges-label-newpage}} (glej tudi [[Special:NewPages|seznam novih strani]])",
        "recentchanges-submit": "Prikaži",
        "rcfilters-activefilters": "Dejavni filtri",
+       "rcfilters-restore-default-filters": "Obnovi privzete filtre",
+       "rcfilters-clear-all-filters": "Počisti vse filtre",
        "rcfilters-search-placeholder": "Zadnje spremembe filtrov (prebrskajte ali začnite vnašati)",
        "rcfilters-invalid-filter": "Neveljaven filter",
+       "rcfilters-empty-filter": "Ni dejavnih filtrov. Prikazani so vsi prispevki.",
        "rcfilters-filterlist-title": "Filtri",
        "rcfilters-filterlist-noresults": "Nismo našli nobenega filtra",
        "rcfilters-filtergroup-registration": "Registracija uporabnika",
index cd5e3b9..22f109d 100644 (file)
@@ -1755,8 +1755,11 @@ return [
                ],
                'messages' => [
                        'rcfilters-activefilters',
+                       'rcfilters-restore-default-filters',
+                       'rcfilters-clear-all-filters',
                        'rcfilters-search-placeholder',
                        'rcfilters-invalid-filter',
+                       'rcfilters-empty-filter',
                        'rcfilters-filterlist-title',
                        'rcfilters-filterlist-noresults',
                        'rcfilters-filtergroup-registration',
@@ -1799,6 +1802,7 @@ return [
                'dependencies' => [
                        'oojs-ui',
                        'mediawiki.Uri',
+                       'oojs-ui.styles.icons-moderation'
                ],
        ],
        'mediawiki.special' => [
index f6fef5b..5dfb68d 100644 (file)
         * @cfg {string} [group] The group this item belongs to
         * @cfg {string} [label] The label for the filter
         * @cfg {string} [description] The description of the filter
-        * @cfg {boolean} [selected] Filter is selected
         * @cfg {boolean} [active=true] The filter is active and affecting the result
         * @cfg {string[]} [excludes=[]] A list of filter names this filter, if
         *  selected, makes inactive.
+        * @cfg {boolean} [default] The default state of this filter
         */
        mw.rcfilters.dm.FilterItem = function MwRcfiltersDmFilterItem( name, config ) {
                config = config || {};
                this.group = config.group || '';
                this.label = config.label || this.name;
                this.description = config.description;
+               this.default = !!config.default;
 
-               this.selected = !!config.selected;
                this.active = config.active === undefined ? true : !!config.active;
                this.excludes = config.excludes || [];
+               this.selected = this.default;
        };
 
        /* Initialization */
                return this.description;
        };
 
+       /**
+        * Get the default value of this filter
+        *
+        * @return {boolean} Filter default
+        */
+       mw.rcfilters.dm.FilterItem.prototype.getDefault = function () {
+               return this.default;
+       };
+
        /**
         * Get the selected state of this filter
         *
index 59a34f4..3f7fa53 100644 (file)
@@ -14,6 +14,8 @@
 
                this.groups = {};
                this.excludedByMap = {};
+               this.defaultParams = {};
+               this.defaultFiltersEmpty = null;
 
                // Events
                this.aggregate( { update: 'filterItemUpdate' } );
         * @param {Object} filters Filter group definition
         */
        mw.rcfilters.dm.FiltersViewModel.prototype.initializeFilters = function ( filters ) {
-               var i, filterItem, excludedFilters,
+               var i, filterItem, selectedFilterNames, excludedFilters,
                        model = this,
                        items = [],
                        addToMap = function ( excludedFilters ) {
                        model.groups[ group ].separator = data.separator || '|';
                        model.groups[ group ].exclusionType = data.exclusionType || 'default';
 
+                       selectedFilterNames = [];
                        for ( i = 0; i < data.filters.length; i++ ) {
                                excludedFilters = data.filters[ i ].excludes || [];
 
                                        label: data.filters[ i ].label,
                                        description: data.filters[ i ].description,
                                        selected: data.filters[ i ].selected,
-                                       excludes: excludedFilters
+                                       excludes: excludedFilters,
+                                       'default': data.filters[ i ].default
                                } );
 
                                // Map filters and what excludes them
                                addToMap( excludedFilters );
 
+                               if ( data.type === 'send_unselected_if_any' ) {
+                                       // Store the default parameter state
+                                       // For this group type, parameter values are direct
+                                       model.defaultParams[ data.filters[ i ].name ] = Number( !!data.filters[ i ].default );
+                               } else if (
+                                       data.type === 'string_options' &&
+                                       data.filters[ i ].default
+                               ) {
+                                       selectedFilterNames.push( data.filters[ i ].name );
+                               }
+
                                model.groups[ group ].filters.push( filterItem );
                                items.push( filterItem );
                        }
+
+                       if ( data.type === 'string_options' ) {
+                               // Store the default parameter group state
+                               // For this group, the parameter is group name and value is the names
+                               // of selected items
+                               model.defaultParams[ group ] = model.sanitizeStringOptionGroup( group, selectedFilterNames ).join( model.groups[ group ].separator );
+                       }
                } );
 
                this.addItems( items );
+
                this.emit( 'initialize' );
        };
 
                return result;
        };
 
+       /**
+        * Get the default parameters object
+        *
+        * @return {Object} Default parameter values
+        */
+       mw.rcfilters.dm.FiltersViewModel.prototype.getDefaultParams = function () {
+               return this.defaultParams;
+       };
+
+       /**
+        * Set all filter states to default values
+        */
+       mw.rcfilters.dm.FiltersViewModel.prototype.setFiltersToDefaults = function () {
+               var defaultFilterStates = this.getFiltersFromParameters( this.getDefaultParams() );
+
+               this.updateFilters( defaultFilterStates );
+       };
+
        /**
         * Analyze the groups and their filters and output an object representing
         * the state of the parameters they represent.
         *
+        * @param {Object} [filterGroups] An object defining the filter groups to
+        *  translate to parameters. Its structure must follow that of this.groups
+        *  see #getFilterGroups
         * @return {Object} Parameter state object
         */
-       mw.rcfilters.dm.FiltersViewModel.prototype.getParametersFromFilters = function () {
+       mw.rcfilters.dm.FiltersViewModel.prototype.getParametersFromFilters = function ( filterGroups ) {
                var i, filterItems, anySelected, values,
                        result = {},
-                       groupItems = this.getFilterGroups();
+                       groupItems = filterGroups || this.getFilterGroups();
 
                $.each( groupItems, function ( group, data ) {
                        filterItems = data.filters;
         * Remove duplicates and make sure to only use valid
         * values.
         *
+        * @private
         * @param {string} groupName Group name
         * @param {string[]} valueArray Array of values
         * @return {string[]} Array of valid values
                return result;
        };
 
+       /**
+        * Check whether the current filter state is set to all false.
+        *
+        * @return {boolean} Current filters are all empty
+        */
+       mw.rcfilters.dm.FiltersViewModel.prototype.areCurrentFiltersEmpty = function () {
+               var currFilters = this.getSelectedState();
+
+               return Object.keys( currFilters ).every( function ( filterName ) {
+                       return !currFilters[ filterName ];
+               } );
+       };
+
+       /**
+        * Check whether the default values of the filters are all false.
+        *
+        * @return {boolean} Default filters are all false
+        */
+       mw.rcfilters.dm.FiltersViewModel.prototype.areDefaultFiltersEmpty = function () {
+               var defaultFilters;
+
+               if ( this.defaultFiltersEmpty !== null ) {
+                       // We only need to do this test once,
+                       // because defaults are set once per session
+                       defaultFilters = this.getFiltersFromParameters();
+                       this.defaultFiltersEmpty = Object.keys( defaultFilters ).every( function ( filterName ) {
+                               return !defaultFilters[ filterName ];
+                       } );
+               }
+
+               return this.defaultFiltersEmpty;
+       };
+
        /**
         * This is the opposite of the #getParametersFromFilters method; this goes over
-        * the parameters and translates into a selected/unselected value in the filters.
+        * the given parameters and translates into a selected/unselected value in the filters.
         *
         * @param {Object} params Parameters query object
         * @return {Object} Filter state object
                var i, filterItem,
                        groupMap = {},
                        model = this,
-                       base = this.getParametersFromFilters(),
-                       // Start with current state
-                       result = this.getSelectedState();
+                       base = this.getDefaultParams(),
+                       result = {};
 
                params = $.extend( {}, base, params );
 
                } )[ 0 ];
        };
 
+       /**
+        * Set all filters to false or empty/all
+        * This is equivalent to display all.
+        */
+       mw.rcfilters.dm.FiltersViewModel.prototype.emptyAllFilters = function () {
+               var filters = {};
+
+               this.getItems().forEach( function ( filterItem ) {
+                       filters[ filterItem.getName() ] = false;
+               } );
+
+               // Update filters
+               this.updateFilters( filters );
+       };
+
        /**
         * Toggle selected state of items by their names
         *
index ea44b8b..28d9f28 100644 (file)
@@ -6,7 +6,6 @@
         */
        mw.rcfilters.Controller = function MwRcfiltersController( model ) {
                this.model = model;
-
                // TODO: When we are ready, update the URL when a filter is updated
                // this.model.connect( this, { itemUpdate: 'updateURL' } );
        };
        mw.rcfilters.Controller.prototype.initialize = function () {
                var uri = new mw.Uri();
 
+               // Give the model a full parameter state from which to
+               // update the filters
                this.model.updateFilters(
                        // Translate the url params to filter select states
                        this.model.getFiltersFromParameters( uri.query )
                );
        };
 
+       /**
+        * Reset to default filters
+        */
+       mw.rcfilters.Controller.prototype.resetToDefaults = function () {
+               this.model.setFiltersToDefaults();
+       };
+
+       /**
+        * Empty all selected filters
+        */
+       mw.rcfilters.Controller.prototype.emptyFilters = function () {
+               this.model.emptyAllFilters();
+       };
+
        /**
         * Update the state of a filter
         *
index 9f4ad48..7b29d4b 100644 (file)
                                                {
                                                        name: 'hidebots',
                                                        label: mw.msg( 'rcfilters-filter-bots-label' ),
-                                                       description: mw.msg( 'rcfilters-filter-bots-description' )
+                                                       description: mw.msg( 'rcfilters-filter-bots-description' ),
+                                                       'default': true
                                                },
                                                {
                                                        name: 'hidehumans',
                                                        label: mw.msg( 'rcfilters-filter-humans-label' ),
-                                                       description: mw.msg( 'rcfilters-filter-humans-description' )
+                                                       description: mw.msg( 'rcfilters-filter-humans-description' ),
+                                                       'default': false
                                                }
                                        ]
                                },
                                                {
                                                        name: 'hidepageedits',
                                                        label: mw.msg( 'rcfilters-filter-pageedits-label' ),
-                                                       description: mw.msg( 'rcfilters-filter-pageedits-description' )
+                                                       description: mw.msg( 'rcfilters-filter-pageedits-description' ),
+                                                       'default': false
                                                },
                                                {
                                                        name: 'hidenewpages',
                                                        label: mw.msg( 'rcfilters-filter-newpages-label' ),
-                                                       description: mw.msg( 'rcfilters-filter-newpages-description' )
+                                                       description: mw.msg( 'rcfilters-filter-newpages-description' ),
+                                                       'default': false
                                                },
                                                {
                                                        name: 'hidecategorization',
                                                        label: mw.msg( 'rcfilters-filter-categorization-label' ),
-                                                       description: mw.msg( 'rcfilters-filter-categorization-description' )
+                                                       description: mw.msg( 'rcfilters-filter-categorization-description' ),
+                                                       'default': true
                                                },
                                                {
                                                        name: 'hidelog',
                                                        label: mw.msg( 'rcfilters-filter-logactions-label' ),
-                                                       description: mw.msg( 'rcfilters-filter-logactions-description' )
+                                                       description: mw.msg( 'rcfilters-filter-logactions-description' ),
+                                                       'default': false
                                                }
                                        ]
                                }
index ea1671b..2ff731c 100644 (file)
@@ -8,6 +8,27 @@
                opacity: 0.5;
        }
 
+       &-emptyFilters {
+               color: #72777d;
+       }
+
+       &-table {
+               display: table;
+               width: 100%;
+       }
+
+       &-row {
+               display: table-row;
+       }
+
+       &-cell {
+               display: table-cell;
+
+               &:last-child {
+                       text-align: right;
+               }
+       }
+
        .oo-ui-capsuleItemWidget {
                color: #222;
                background-color: #fff;
index a610e8f..f138d7e 100644 (file)
@@ -17,7 +17,7 @@
        &-popup {
                // We have to override OOUI's definition, which is set
                // on the inline style of the popup
-               margin-top: 2em !important;
+               margin-top: 2.4em !important;
                max-width: 650px;
        }
 
index db21542..c498ce9 100644 (file)
@@ -5,15 +5,19 @@
         * @extends OO.ui.CapsuleMultiselectWidget
         *
         * @constructor
+        * @param {mw.rcfilters.Controller} controller RCFilters controller
+        * @param {mw.rcfilters.dm.FiltersViewModel} model RCFilters view model
         * @param {OO.ui.InputWidget} filterInput A filter input that focuses the capsule widget
         * @param {Object} config Configuration object
         */
-       mw.rcfilters.ui.FilterCapsuleMultiselectWidget = function MwRcfiltersUiFilterCapsuleMultiselectWidget( filterInput, config ) {
+       mw.rcfilters.ui.FilterCapsuleMultiselectWidget = function MwRcfiltersUiFilterCapsuleMultiselectWidget( controller, model, filterInput, config ) {
                // Parent
                mw.rcfilters.ui.FilterCapsuleMultiselectWidget.parent.call( this, $.extend( {
                        $autoCloseIgnore: filterInput.$element
                }, config ) );
 
+               this.controller = controller;
+               this.model = model;
                this.filterInput = filterInput;
 
                this.$content.prepend(
                                .text( mw.msg( 'rcfilters-activefilters' ) )
                );
 
+               this.resetButton = new OO.ui.ButtonWidget( {
+                       icon: 'trash',
+                       framed: false,
+                       title: mw.msg( 'rcfilters-clear-all-filters' ),
+                       classes: [ 'mw-rcfilters-ui-filterCapsuleMultiselectWidget-resetButton' ]
+               } );
+
+               this.emptyFilterMessage = new OO.ui.LabelWidget( {
+                       label: mw.msg( 'rcfilters-empty-filter' ),
+                       classes: [ 'mw-rcfilters-ui-filterCapsuleMultiselectWidget-emptyFilters' ]
+               } );
+
                // Events
+               this.resetButton.connect( this, { click: 'onResetButtonClick' } );
+               this.model.connect( this, { itemUpdate: 'onModelItemUpdate' } );
                // Add the filterInput as trigger
                this.filterInput.$input
                        .on( 'focus', this.focus.bind( this ) );
 
+               // Initialize
+               this.$content.append( this.emptyFilterMessage.$element );
+               this.$handle
+                       .append(
+                               // The content and button should appear side by side regardless of how
+                               // wide the button is; the button also changes its width depending
+                               // on language and its state, so the safest way to present both side
+                               // by side is with a table layout
+                               $( '<div>' )
+                                       .addClass( 'mw-rcfilters-ui-filterCapsuleMultiselectWidget-table' )
+                                       .append(
+                                               $( '<div>' )
+                                                       .addClass( 'mw-rcfilters-ui-filterCapsuleMultiselectWidget-row' )
+                                                       .append(
+                                                               $( '<div>' )
+                                                                       .addClass( 'mw-rcfilters-ui-filterCapsuleMultiselectWidget-content' )
+                                                                       .addClass( 'mw-rcfilters-ui-filterCapsuleMultiselectWidget-cell' )
+                                                                       .append( this.$content ),
+                                                               $( '<div>' )
+                                                                       .addClass( 'mw-rcfilters-ui-filterCapsuleMultiselectWidget-cell' )
+                                                                       .append( this.resetButton.$element )
+                                                       )
+                                       )
+                       );
+
                this.$element
                        .addClass( 'mw-rcfilters-ui-filterCapsuleMultiselectWidget' );
+
+               this.reevaluateResetRestoreState();
        };
 
        /* Initialization */
 
        /* Methods */
 
+       mw.rcfilters.ui.FilterCapsuleMultiselectWidget.prototype.onModelItemUpdate = function () {
+               // Re-evaluate reset state
+               this.reevaluateResetRestoreState();
+       };
+
+       /**
+        * Respond to click event on the reset button
+        */
+       mw.rcfilters.ui.FilterCapsuleMultiselectWidget.prototype.onResetButtonClick = function () {
+               if ( this.model.areCurrentFiltersEmpty() ) {
+                       // Reset to default filters
+                       this.controller.resetToDefaults();
+               } else {
+                       // Reset to have no filters
+                       this.controller.emptyFilters();
+               }
+       };
+
+       /**
+        * Reevaluate the restore state for the widget between setting to defaults and clearing all filters
+        */
+       mw.rcfilters.ui.FilterCapsuleMultiselectWidget.prototype.reevaluateResetRestoreState = function () {
+               var defaultsAreEmpty = this.model.areDefaultFiltersEmpty(),
+                       currFiltersAreEmpty = this.model.areCurrentFiltersEmpty(),
+                       hideResetButton = currFiltersAreEmpty && defaultsAreEmpty;
+
+               this.resetButton.setIcon(
+                       currFiltersAreEmpty ? 'history' : 'trash'
+               );
+
+               this.resetButton.setLabel(
+                       currFiltersAreEmpty ? mw.msg( 'rcfilters-restore-default-filters' ) : ''
+               );
+
+               this.resetButton.toggle( !hideResetButton );
+               this.emptyFilterMessage.toggle( currFiltersAreEmpty );
+       };
+
        /**
         * @inheritdoc
         */
index 3353e54..34cc240 100644 (file)
@@ -37,7 +37,7 @@
                        placeholder: mw.msg( 'rcfilters-search-placeholder' )
                } );
 
-               this.capsule = new mw.rcfilters.ui.FilterCapsuleMultiselectWidget( this.textInput, {
+               this.capsule = new mw.rcfilters.ui.FilterCapsuleMultiselectWidget( controller, this.model, this.textInput, {
                        popup: {
                                $content: this.filterPopup.$element,
                                classes: [ 'mw-rcfilters-ui-filterWrapperWidget-popup' ]
@@ -99,6 +99,7 @@
         */
        mw.rcfilters.ui.FilterWrapperWidget.prototype.onModelInitialize = function () {
                var items,
+                       wrapper = this,
                        filters = this.model.getItems();
 
                // Reset
                } );
 
                this.capsule.getMenu().addItems( items );
+
+               // Add defaults to capsule. We have to do this
+               // after we added to the capsule menu, since that's
+               // how the capsule multiselect widget knows which
+               // object to add
+               filters.forEach( function ( filterItem ) {
+                       if ( filterItem.isSelected() ) {
+                               wrapper.addCapsuleItemFromName( filterItem.getName() );
+                       }
+               } );
        };
 
        /**
                var widget = this;
 
                if ( item.isSelected() ) {
-                       this.capsule.addItemsFromData( [ item.getName() ] );
-
-                       // Deal with active/inactive capsule filter items
-                       this.capsule.getItemFromData( item.getName() ).$element
-                               .toggleClass( 'mw-rcfilters-ui-filterCapsuleMultiselectWidget-item-inactive', !item.isActive() );
+                       this.addCapsuleItemFromName( item.getName() );
                } else {
                        this.capsule.removeItemsFromData( [ item.getName() ] );
                }
                        }
                } );
        };
+
+       /**
+        * Add a capsule item by its filter name
+        *
+        * @param {string} itemName Filter name
+        */
+       mw.rcfilters.ui.FilterWrapperWidget.prototype.addCapsuleItemFromName = function ( itemName ) {
+               var item = this.model.getItemByName( itemName );
+
+               this.capsule.addItemsFromData( [ itemName ] );
+
+               // Deal with active/inactive capsule filter items
+               this.capsule.getItemFromData( itemName ).$element
+                       .toggleClass( 'mw-rcfilters-ui-filterCapsuleMultiselectWidget-item-inactive', !item.isActive() );
+       };
 }( mediaWiki ) );
index a62ef2e..87e209e 100644 (file)
@@ -123,7 +123,6 @@ table.toc td {
 /* Images */
 /* @noflip */div.floatright, table.floatright {
        margin: 0 0 .5em .5em;
-       border: 0;
 }
 
 div.floatright p {
@@ -132,7 +131,6 @@ div.floatright p {
 
 /* @noflip */div.floatleft, table.floatleft {
        margin: 0 .5em .5em 0;
-       border: 0;
 }
 
 div.floatleft p {
index 281e1df..97e24b6 100644 (file)
@@ -974,7 +974,10 @@ class ParserTestRunner {
                        'wgEnableUploads' => self::getOptionValue( 'wgEnableUploads', $opts, true ),
                        'wgLanguageCode' => $langCode,
                        'wgRawHtml' => self::getOptionValue( 'wgRawHtml', $opts, false ),
-                       'wgNamespacesWithSubpages' => [ 0 => isset( $opts['subpage'] ) ],
+                       'wgNamespacesWithSubpages' => [
+                               0 => isset( $opts['subpage'] ),
+                               2 => isset( $opts['subpage'] ),
+                       ],
                        'wgMaxTocLevel' => $maxtoclevel,
                        'wgAllowExternalImages' => self::getOptionValue( 'wgAllowExternalImages', $opts, true ),
                        'wgThumbLimits' => [ self::getOptionValue( 'thumbsize', $opts, 180 ) ],
index ed09203..1563525 100644 (file)
@@ -933,6 +933,7 @@ Italics and bold: 5-quote opening sequence: (5,6)
 ###
 ### multiple quote sequences in a line
 ###
+
 !! test
 Italics and bold: multiple quote sequences: (2,4,2)
 !! options
@@ -942,8 +943,7 @@ parsoid=wt2html
 !! html/*
 <p><i>foo'<b>bar</b></i>
 </p>
-!!end
-
+!! end
 
 # same html as previous, but wikitext adjusted to match parsoid html2wt
 !! test
@@ -955,7 +955,6 @@ Italics and bold: multiple quote sequences: (2,4,2+3) w/ nowiki
 </p>
 !! end
 
-
 !! test
 Italics and bold: multiple quote sequences: (2,4,3)
 !! options
@@ -965,8 +964,7 @@ parsoid=wt2html
 !! html/*
 <p><i>foo'<b>bar</b></i>
 </p>
-!!end
-
+!! end
 
 # same html as previous, but wikitext adjusted to match parsoid html2wt
 !! test
@@ -978,7 +976,6 @@ Italics and bold: multiple quote sequences: (2,4,3+2) w/ nowiki
 </p>
 !! end
 
-
 !! test
 Italics and bold: multiple quote sequences: (2,4,4)
 !! options
@@ -988,8 +985,7 @@ parsoid=wt2html
 !! html/*
 <p><i>foo'<b>bar'</b></i>
 </p>
-!!end
-
+!! end
 
 # same html as previous, but wikitext adjusted to match parsoid html2wt
 !! test
@@ -1001,7 +997,6 @@ Italics and bold: multiple quote sequences: (2,4,4+2) w/ nowiki
 </p>
 !! end
 
-
 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
 !! test
 Italics and bold: multiple quote sequences: (3,4,2)
@@ -1015,24 +1010,21 @@ parsoid=wt2html
 !! html/parsoid
 <p><b>foo'</b>bar<i></i>
 </p>
-!!end
+!! end
 
 # same html as previous, but wikitext adjusted to match parsoid html2wt
 !! test
 Italics and bold: multiple quote sequences: (3,4,2+2) w/ nowiki
-!! options
-parsoid
 !! wikitext
-'''<nowiki>foo'</nowiki>'''bar''<nowiki/>''
+'''foo''''bar''<nowiki/>''
 !! html/php
 <p><b>foo'</b>bar
 </p>
 !! html/parsoid
-<p><b><span typeof="mw:Nowiki">foo'</span></b>bar<i></i>
+<p><b>foo'</b>bar<i></i>
 </p>
 !! end
 
-
 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
 !! test
 Italics and bold: multiple quote sequences: (3,4,3)
@@ -1046,18 +1038,18 @@ parsoid=wt2html
 !! html/parsoid
 <p><b>foo'</b>bar<b></b>
 </p>
-!!end
+!! end
 
 # same html as previous, but wikitext adjusted to match parsoid html2wt
 !! test
 Italics and bold: multiple quote sequences: (3,4,3+3) w/ nowiki
 !! wikitext
-'''<nowiki>foo'</nowiki>'''bar'''<nowiki/>'''
+'''foo''''bar'''<nowiki/>'''
 !! html/php
 <p><b>foo'</b>bar
 </p>
 !! html/parsoid
-<p><b><span typeof="mw:Nowiki">foo'</span></b>bar<b></b>
+<p><b>foo'</b>bar<b></b>
 </p>
 !! end
 
@@ -1135,7 +1127,7 @@ The ''[[Main Page]]'''s talk page.
 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
 </p>
 !! html/parsoid
-<p>The <i><a rel="mw:WikiLink"  href="Main_Page" title="Main Page">Main Page</a>'</i>s talk page.</p>
+<p>The <i><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a>'</i>s talk page.</p>
 !! end
 
 !! test
@@ -2861,9 +2853,9 @@ Parsoid: pipe in transclusion parameter
 !! html/php+tidy
 <p><a rel="nofollow" class="external free" href="http://foo.com/a%7Cb">http://foo.com/a%7Cb</a></p>
 !! html/parsoid
-<p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
+<p><a rel="mw:ExtLink" href="http://foo.com/a%7Cb" about="#mwt1"
 typeof="mw:Transclusion"
-data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"http://foo.com/a&amp;#124;b"}},"i":0}}]}'>http://foo.com/a|b</a></p>
+data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"http://foo.com/a&amp;#124;b"}},"i":0}}]}'>http://foo.com/a%7Cb</a></p>
 !! end
 
 !! test
@@ -4798,6 +4790,17 @@ news:'a'b''c''d e
 <p><a rel="mw:ExtLink" href="news:'a'b">news:'a'b</a><i>c</i>d e</p>
 !! end
 
+!! test
+External links: with entity
+!! wikitext
+[http://&#x20;www.librarieswithoutborders.org Libraries without borders]
+!! html/php
+<p><a rel="nofollow" class="external text" href="http://+www.librarieswithoutborders.org">Libraries without borders</a>
+</p>
+!! html/parsoid
+<p><a rel="mw:ExtLink" href="http://+www.librarieswithoutborders.org" data-parsoid='{"a":{"href":"http://+www.librarieswithoutborders.org"},"sa":{"href":"http://&amp;#x20;www.librarieswithoutborders.org"}}'>Libraries without borders</a></p>
+!! end
+
 !! test
 External links: Lone protocols are never linked (T105697)
 !! wikitext
@@ -5460,7 +5463,7 @@ http://example.com/index.php?foozoid&#x5B;&#x5D;=bar
 !! html/parsoid
 <p><a rel="mw:ExtLink" href="http://example.com/index.php?foozoid%5B%5D=bar">http://example.com/index.php?foozoid%5B%5D=bar</a></p>
 
-<p><a rel="mw:ExtLink" href="http://example.com/index.php?foozoid[]=bar">http://example.com/index.php?foozoid[]=bar</a></p>
+<p><a rel="mw:ExtLink" href="http://example.com/index.php?foozoid%5B%5D=bar" data-parsoid='{"stx":"url","a":{"href":"http://example.com/index.php?foozoid%5B%5D=bar"},"sa":{"href":"http://example.com/index.php?foozoid&amp;#x5B;&amp;#x5D;=bar"}}'>http://example.com/index.php?foozoid%5B%5D=bar</a></p>
 !! end
 
 !! test
@@ -6407,7 +6410,7 @@ parsoid=wt2html,html2html
 !! html/parsoid
 <table><tbody>
 <tr>
-<td data-parsoid='{"startTagSrc":"| ","attrSepSrc":"|","autoInsertedEnd":true}'><a rel="mw:ExtLink" href="ftp://|x||"></a>" onmouseover="alert(document.cookie)">test</td></tr></tbody></table>
+<td data-parsoid='{"startTagSrc":"| ","attrSepSrc":"|","autoInsertedEnd":true}'>[<a rel="mw:ExtLink" href="ftp://%7Cx" data-parsoid='{"stx":"url","a":{"href":"ftp://%7Cx"},"sa":{"href":"ftp://|x"}}'>ftp://%7Cx</a></td><td data-parsoid='{"stx_v":"row","autoInsertedEnd":true}'>]" onmouseover="alert(document.cookie)">test</td></tr></tbody></table>
 !! end
 
 !! test
@@ -7485,7 +7488,7 @@ Piped link with multiple pipe characters in link text
 <p><a href="/wiki/Main_Page" title="Main Page">|The|Main|Page|</a>
 </p>
 !! html/parsoid
-<p><a rel="mw:WikiLink" href="Main_Page" title="Main Page">|The|Main|Page|</a></p>
+<p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">|The|Main|Page|</a></p>
 !! end
 
 !! test
@@ -7841,6 +7844,17 @@ Link containing double-single-quotes '' (bug 4598)
 <p><a rel="mw:WikiLink" href="./Lista_d''e_paise_d''o_munno" title="Lista d''e paise d''o munno">Lista d''e paise d''o munno</a></p>
 !! end
 
+!! test
+Link containing double quotes and spaces
+!! wikitext
+[[Cool "Gator"]]
+!! html/php
+<p><a href="/index.php?title=Cool_%22Gator%22&amp;action=edit&amp;redlink=1" class="new" title="Cool &quot;Gator&quot; (page does not exist)">Cool "Gator"</a>
+</p>
+!! html/parsoid
+<p><a rel="mw:WikiLink" href="./Cool_%22Gator%22" title='Cool "Gator"'>Cool "Gator"</a></p>
+!! end
+
 !! test
 Link containing double-single-quotes '' in text (bug 4598 sanity check)
 !! wikitext
@@ -7849,7 +7863,7 @@ Some [[Link|pretty ''italics'' and stuff]]!
 <p>Some <a href="/index.php?title=Link&amp;action=edit&amp;redlink=1" class="new" title="Link (page does not exist)">pretty <i>italics</i> and stuff</a>!
 </p>
 !! html/parsoid
-<p>Some <a rel="mw:WikiLink" href="Link" title="Link">pretty <i>italics</i> and stuff</a>!</p>
+<p>Some <a rel="mw:WikiLink" href="./Link" title="Link">pretty <i>italics</i> and stuff</a>!</p>
 !! end
 
 !! test
@@ -7879,9 +7893,9 @@ Link with double quotes in title part (literal) and alternate part (interpreted)
 </p>
 !! html/parsoid
 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="./File:Denys_Savchenko_''Pentecoste''.jpg"><img resource="./File:Denys_Savchenko_''Pentecoste''.jpg" src="./Special:FilePath/Denys_Savchenko_''Pentecoste''.jpg" height="220" width="220"/></a></span></p>
-<p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''">''Pentecoste''</a></p>
-<p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''">Pentecoste</a></p>
-<p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''"><i>Pentecoste</i></a></p>
+<p><a rel="mw:WikiLink" href="./''Pentecoste''" title="''Pentecoste''">''Pentecoste''</a></p>
+<p><a rel="mw:WikiLink" href="./''Pentecoste''" title="''Pentecoste''">Pentecoste</a></p>
+<p><a rel="mw:WikiLink" href="./''Pentecoste''" title="''Pentecoste''"><i>Pentecoste</i></a></p>
 !! end
 
 !! test
@@ -7976,7 +7990,7 @@ Piped link to URL: [[http://www.example.com|an example URL]]
 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
 </p>
 !! html/parsoid
-<p>Piped link to URL: [<a rel="mw:ExtLink" href="http://www.example.com|an">example URL</a>]</p>
+<p>Piped link to URL: [<a rel="mw:ExtLink" href="http://www.example.com%7Can" data-parsoid='{"a":{"href":"http://www.example.com%7Can"},"sa":{"href":"http://www.example.com|an"}}'>example URL</a>]</p>
 !! end
 
 !! test
@@ -8134,19 +8148,32 @@ Link with multiple ":" in a subpage-supporting namespace (bug 63636)
 Handle title parsing for subpages
 !! options
 title=[[/123123]]
+subpage
 !! wikitext
 123
+!! html/php
+<p>123
+</p>
 !! html/parsoid
 <p>123</p>
 !! end
 
-## FIXME: Add a working php section here
+!! article
+User:Test/123
+!! text
+test 123
+!! endarticle
+
 !! test
 Link to a subpage from a namespace other than main
 !! options
-title=[[User:test]]
+title=[[User:Test]]
+subpage
 !! wikitext
 [[/123]]
+!! html/php
+<p><a href="/wiki/User:Test/123" title="User:Test/123">/123</a>
+</p>
 !! html/parsoid
 <p><a rel="mw:WikiLink" href="./User:Test/123" title="User:Test/123" data-parsoid='{"stx":"simple","a":{"href":"./User:Test/123"},"sa":{"href":"/123"}}'>/123</a></p>
 !! end
@@ -8168,7 +8195,8 @@ parsoid=wt2html
 !! test
 Purely hash wikilink
 !! options
-title=[[User:test/123]]
+title=[[User:Test/123]]
+subpage
 !! wikitext
 [[#a|b]]
 !! html/php
@@ -8180,12 +8208,10 @@ title=[[User:test/123]]
 
 !! test
 1. Interaction of linktrail and template encapsulation
-!! options
-parsoid
 !! wikitext
 {{echo|[[Foo]]}}l
-!! html
-<p><a rel="mw:WikiLink" href="Foo" title="Foo" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Foo]]"}},"i":0}},"l"]}'>Fool</a></p>
+!! html/parsoid
+<p><a rel="mw:WikiLink" href="./Foo" title="Foo" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Foo]]"}},"i":0}},"l"]}'>Fool</a></p>
 !! end
 
 !! test
@@ -8255,7 +8281,7 @@ Parsoid link trail escaping
 !! options
 parsoid=html2wt,html2html
 !! html/parsoid
-<p><a rel="mw:WikiLink" href="Apple" title="Apple">apple</a>s</p>
+<p><a rel="mw:WikiLink" href="./Apple" title="Apple">apple</a>s</p>
 !! wikitext
 [[apple]]<nowiki/>s
 !! end
@@ -8266,7 +8292,7 @@ Parsoid link prefix escaping
 language=is
 parsoid=html2wt,html2html
 !! html/parsoid
-<p>Aðrir mótmælenda<a rel="mw:WikiLink" href="Söfnuður" title="Söfnuður">söfnuður</a></p>
+<p>Aðrir mótmælenda<a rel="mw:WikiLink" href="./Söfnuður" title="Söfnuður">söfnuður</a></p>
 !! wikitext
 Aðrir mótmælenda<nowiki/>[[söfnuður]]
 !! end
@@ -8291,12 +8317,10 @@ Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
 
 !! test
 Parsoid: Scoped parsing should handle mixed transclusions and plain text
-!! options
-parsoid
 !! wikitext
 [[Foo|{{echo|a}} b {{echo|c}}]]
-!! html
-<p><a rel="mw:WikiLink" href="Foo" title="Foo"><span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a"}},"i":0}}]}'>a</span> b <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"c"}},"i":0}}]}'>c</span></a></p>
+!! html/parsoid
+<p><a rel="mw:WikiLink" href="./Foo" title="Foo"><span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a"}},"i":0}}]}'>a</span> b <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"c"}},"i":0}}]}'>c</span></a></p>
 !! end
 
 !! test
@@ -8711,8 +8735,8 @@ Parsoid bug 53221: Wikilinks should be properly entity-escaped
 !! options
 parsoid={ "modes": ["html2wt"], "suppressErrors": true }
 !! html/parsoid
-<p>He&amp;nbsp;llo <a href="Foo" rel="mw:WikiLink">He&amp;nbsp;llo</a></p>
-<p>He&amp;nbsp;llo <a href="He&amp;nbsp;llo" rel="mw:WikiLink">He&amp;nbsp;llo</a></p>
+<p>He&amp;nbsp;llo <a href="./Foo" rel="mw:WikiLink">He&amp;nbsp;llo</a></p>
+<p>He&amp;nbsp;llo <a href="./He&amp;nbsp;llo" rel="mw:WikiLink">He&amp;nbsp;llo</a></p>
 !! wikitext
 He&amp;nbsp;llo [[Foo|He&amp;nbsp;llo]]
 
@@ -10361,7 +10385,7 @@ Parsoid: Page property magic word with magic word contents
 !! wikitext
 {{DISPLAYTITLE:''{{PAGENAME}}''}}
 !! html/parsoid
-<meta property="mw:PageProp/displaytitle" content="Main Page" about="#mwt2" typeof="mw:ExpandedAttrs" data-parsoid='{"src":"{{DISPLAYTITLE:&#39;&#39;{{PAGENAME}}&#39;&#39;}}"}' data-mw='{"attribs":[[{"txt":"content"},{"html":"&lt;i data-parsoid=&#39;{\"dsr\":[15,31,2,2]}&#39;>&lt;span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid=&#39;{\"pi\":[[]],\"dsr\":[17,29,null,null]}&#39; data-mw=&#39;{\"parts\":[{\"template\":{\"target\":{\"wt\":\"PAGENAME\",\"function\":\"pagename\"},\"params\":{},\"i\":0}}]}&#39;>Main Page&lt;/span>&lt;/i>"}]]}'/>
+<meta property="mw:PageProp/displaytitle" content="Main Page" about="#mwt3" typeof="mw:ExpandedAttrs" data-parsoid='{"src":"{{DISPLAYTITLE:&#39;&#39;{{PAGENAME}}&#39;&#39;}}"}' data-mw='{"attribs":[[{"txt":"content"},{"html":"&lt;i data-parsoid=&#39;{\"dsr\":[15,31,2,2]}&#39;>&lt;span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-parsoid=&#39;{\"pi\":[[]],\"dsr\":[17,29,null,null]}&#39; data-mw=&#39;{\"parts\":[{\"template\":{\"target\":{\"wt\":\"PAGENAME\",\"function\":\"pagename\"},\"params\":{},\"i\":0}}]}&#39;>Main Page&lt;/span>&lt;/i>"}]]}'/>
 !! end
 
 !! test
@@ -13577,7 +13601,7 @@ Image with link parameter, wiki target
 <p><a href="/wiki/Main_Page" title="Main Page"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
 </p>
 !! html/parsoid
-<p><span class="mw-default-size" typeof="mw:Image"><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
+<p><span class="mw-default-size" typeof="mw:Image"><a href="./Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
 !! end
 
 # parsoid bug 49293 (part 1)
@@ -13684,7 +13708,7 @@ Image with link parameter (wiki target) and unnamed parameter
 <p><a href="/wiki/Main_Page" title="Title"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
 </p>
 !! html/parsoid
-<p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"Title"}'><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
+<p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"Title"}'><a href="./Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
 !! end
 
 !! test
@@ -13736,7 +13760,7 @@ parsoid=wt2html,wt2wt,html2html
 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a>  <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>Title</div></div></div>
 
 !! html/parsoid
-<figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" data-file-width="135" data-file-height="135" data-file-type="bitmap" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
+<figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="./Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" data-file-width="135" data-file-height="135" data-file-type="bitmap" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
 !! end
 
 !! test
@@ -13778,7 +13802,7 @@ parsoid=wt2html,wt2wt,html2html
 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="alttext" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a>  <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>Title</div></div></div>
 
 !! html/parsoid
-<figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="Main_Page"><img alt="alttext" resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" data-file-width="135" data-file-height="135" data-file-type="bitmap" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
+<figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="./Main_Page"><img alt="alttext" resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" data-file-width="135" data-file-height="135" data-file-type="bitmap" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
 !! end
 
 !! test
@@ -13791,7 +13815,7 @@ parsoid=wt2html,wt2wt,html2html
 <div class="thumb tleft"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a>  <div class="thumbcaption">This is a test image <a href="/wiki/Main_Page" title="Main Page">Main Page</a></div></div></div>
 
 !! html/parsoid
-<figure class="mw-default-size mw-halign-left" typeof="mw:Image/Frame"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="Main_Page" title="Main Page">Main Page</a></figcaption></figure>
+<figure class="mw-default-size mw-halign-left" typeof="mw:Image/Frame"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a></figcaption></figure>
 !! end
 
 !! test
@@ -13804,7 +13828,7 @@ parsoid=wt2html,wt2wt,html2html
 <div class="thumb tleft"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Altitude" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a>  <div class="thumbcaption">This is a test image <a href="/wiki/Main_Page" title="Main Page">Main Page</a></div></div></div>
 
 !! html/parsoid
-<figure class="mw-default-size mw-halign-left" typeof="mw:Image/Frame"><a href="./File:Foobar.jpg"><img alt="Altitude" resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="Main_Page" title="Main Page">Main Page</a></figcaption></figure>
+<figure class="mw-default-size mw-halign-left" typeof="mw:Image/Frame"><a href="./File:Foobar.jpg"><img alt="Altitude" resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a></figcaption></figure>
 !! end
 
 !! test
@@ -14268,7 +14292,7 @@ parsoid=wt2html,wt2wt,html2html
 <p>[[Image:Foobar.jpg|thumb|This is a broken caption. But <a href="/wiki/Main_Page" title="Main Page">this</a> is just an ordinary link.
 </p>
 !! html/parsoid
-<p>[[Image:Foobar.jpg|thumb|This is a broken caption. But <a rel="mw:WikiLink" href="Main_Page" title="Main Page">this</a> is just an ordinary link.</p>
+<p>[[Image:Foobar.jpg|thumb|This is a broken caption. But <a rel="mw:WikiLink" href="./Main_Page" title="Main Page">this</a> is just an ordinary link.</p>
 !! end
 
 !! test
@@ -14381,7 +14405,7 @@ language=es
 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/Foo" title="Foo"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a>  <div class="thumbcaption"><div class="magnify"><a href="/wiki/Archivo:Foobar.jpg" class="internal" title="Aumentar"></a></div>caption</div></div></div>
 
 !! html/parsoid
-<figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="Foo"><img resource="./Archivo:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
+<figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="./Foo"><img resource="./Archivo:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
 !! end
 
 !! test
@@ -14755,8 +14779,8 @@ subpage title=[[Subpage test/1/2/3/4]]
 </p><p><a href="/wiki/Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">Subpage test/1/2/subpage</a>
 </p>
 !! html/parsoid
-<p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">subpage</a></p>
-<p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
+<p><a rel="mw:WikiLink" href="./Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">subpage</a></p>
+<p><a rel="mw:WikiLink" href="./Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
 !! end
 
 !! test
@@ -15046,12 +15070,12 @@ Bar
 Bar
 </p>
 !! html/parsoid
-<p>Foo <link rel="mw:PageProp/Category" href="Category:Baz"/> Bar</p>
-<p>Foo <link rel="mw:PageProp/Category" href="Category:Baz"/> Bar</p>
-<p>Foo <link rel="mw:PageProp/Category" href="Category:Baz"/> Bar</p>
-<p>Foo <link rel="mw:PageProp/Category" href="Category:Baz"/> Bar</p>
-<p>Foo <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz"/> Bar <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Category:Baz]]"}},"i":0}}]}'/></p>
-<link rel="mw:PageProp/Category" href="Category:Baz"/>
+<p>Foo <link rel="mw:PageProp/Category" href="./Category:Baz"/> Bar</p>
+<p>Foo <link rel="mw:PageProp/Category" href="./Category:Baz"/> Bar</p>
+<p>Foo <link rel="mw:PageProp/Category" href="./Category:Baz"/> Bar</p>
+<p>Foo <link rel="mw:PageProp/Category" href="./Category:Baz"/> Bar</p>
+<p>Foo <link rel="mw:PageProp/Category" href="./Category:Baz"/> <link rel="mw:PageProp/Category" href="./Category:Baz"/> <link rel="mw:PageProp/Category" href="./Category:Baz"/> Bar <link rel="mw:PageProp/Category" href="./Category:Baz"/> <link rel="mw:PageProp/Category" href="./Category:Baz"/> <link rel="mw:PageProp/Category" href="./Category:Baz"/> <link rel="mw:PageProp/Category" href="./Category:Baz"/> <link rel="mw:PageProp/Category" href="./Category:Baz" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Category:Baz]]"}},"i":0}}]}'/></p>
+<link rel="mw:PageProp/Category" href="./Category:Baz"/>
 !! end
 
 ## We used to, but no longer wt2wt this test since the default serializer
@@ -16083,7 +16107,7 @@ div with braces in attribute value
 !! wikitext
 <div title="{}">Foo</div>
 !! html/php
-<div title="&#123;}">Foo</div>
+<div title="&#123;&#125;">Foo</div>
 
 !! html/parsoid
 <div title="{}">Foo</div>
@@ -16523,9 +16547,11 @@ Template:Div style
 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
 !! wikitext
 <div title="{{test}}"></div>
-!! html
+!! html/php
 <div title="This is a test template"></div>
 
+!! html/parsoid
+<div title="This is a test template" about="#mwt2" typeof="mw:ExpandedAttrs" data-parsoid='{"stx":"html","a":{"title":"This is a test template"},"sa":{"title":"{{test}}"}}' data-mw='{"attribs":[[{"txt":"title"},{"html":"&lt;span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid=&#39;{\"pi\":[[]],\"dsr\":[12,20,null,null]}&#39; data-mw=&#39;{\"parts\":[{\"template\":{\"target\":{\"wt\":\"test\",\"href\":\"./Template:Test\"},\"params\":{},\"i\":0}}]}&#39;>This is a test template&lt;/span>"}]]}'></div>
 !! end
 
 # Parsoid has enough context to handle this case
@@ -16544,29 +16570,36 @@ Bug 2304: HTML attribute safety (dangerous template; 2309)
 Bug 2304: HTML attribute safety (dangerous style template; 2309)
 !! wikitext
 <div style="{{dangerous style attribute}}"></div>
-!! html
+!! html/php
 <div style="/* insecure input */"></div>
 
+!! html/parsoid
+<div style="/* insecure input */" about="#mwt2" typeof="mw:ExpandedAttrs" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"{{dangerous style attribute}}"}}' data-mw='{"attribs":[[{"txt":"style"},{"html":"&lt;span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid=&#39;{\"pi\":[[]],\"dsr\":[12,41,null,null]}&#39; data-mw=&#39;{\"parts\":[{\"template\":{\"target\":{\"wt\":\"dangerous style attribute\",\"href\":\"./Template:Dangerous_style_attribute\"},\"params\":{},\"i\":0}}]}&#39;>border-size: expression(alert(document.cookie))&lt;/span>"}]]}'></div>
 !! end
 
 !! test
 Bug 2304: HTML attribute safety (safe parameter; 2309)
 !! wikitext
 {{div style|width: 200px}}
-!! html
+!! html/php
 <div style="float: right; width: 200px">Magic div</div>
 
+!! html/parsoid
+<div style="float: right; width: 200px" about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"stx":"html","a":{"style":"float: right; width: 200px"},"sa":{"style":"float: right; {{{1}}}"},"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"div style","href":"./Template:Div_style"},"params":{"1":{"wt":"width: 200px"}},"i":0}}]}'>Magic div</div>
 !! end
 
 !! test
 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
 !! wikitext
 {{div style|width: expression(alert(document.cookie))}}
-!! html
+!! html/php
 <div style="/* insecure input */">Magic div</div>
 
+!! html/parsoid
+<div style="/* insecure input */" about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"float: right; {{{1}}}"},"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"div style","href":"./Template:Div_style"},"params":{"1":{"wt":"width: expression(alert(document.cookie))"}},"i":0}}]}'>Magic div</div>
 !! end
 
+## Parsoid output here differs; needs investigation.
 !! test
 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
 !! wikitext
@@ -16576,6 +16609,7 @@ Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
 
 !! end
 
+## Parsoid output here differs; needs investigation.
 !! test
 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
 !! wikitext
@@ -16612,7 +16646,6 @@ Bug 2304: HTML attribute safety (bold)
 
 !! end
 
-
 !! test
 Bug 2304: HTML attribute safety (ISBN)
 !! wikitext
@@ -16662,18 +16695,22 @@ Bug 2304: HTML attribute safety (named web link)
 Bug 3244: HTML attribute safety (extension; safe)
 !! wikitext
 <div style="<nowiki>background:blue</nowiki>"></div>
-!! html
+!! html/php
 <div style="background:blue"></div>
 
+!! html/parsoid
+<div style="background:blue" data-parsoid='{"stx":"html","a":{"style":"background:blue"},"sa":{"style":"&lt;nowiki>background:blue&lt;/nowiki>"}}'></div>
 !! end
 
 !! test
 Bug 3244: HTML attribute safety (extension; unsafe)
 !! wikitext
 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
-!! html
+!! html/php
 <div style="/* insecure input */"></div>
 
+!! html/parsoid
+<div style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"&lt;nowiki>border-left:expression(alert(document.cookie))&lt;/nowiki>"}}'></div>
 !! end
 
 # More MSIE fun discovered by Tom Gilder
@@ -16682,45 +16719,55 @@ Bug 3244: HTML attribute safety (extension; unsafe)
 MSIE CSS safety test: spurious slash
 !! wikitext
 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
-!! html
+!! html/php
 <div style="/* insecure input */">evil</div>
 
+!! html/parsoid
+<div style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"background-image:u\\rl(javascript:alert(&#39;boo&#39;))"}}'>evil</div>
 !! end
 
 !! test
 MSIE CSS safety test: hex code
 !! wikitext
 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
-!! html
+!! html/php
 <div style="/* insecure input */">evil</div>
 
+!! html/parsoid
+<div style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"background-image:u\\72l(javascript:alert(&#39;boo&#39;))"}}'>evil</div>
 !! end
 
 !! test
 MSIE CSS safety test: comment in url
 !! wikitext
 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
-!! html
+!! html/php
 <div style="background-image:u rl(javascript:alert(&#39;boo&#39;))">evil</div>
 
+!! html/parsoid
+<div style="background-image:u rl(javascript:alert('boo'))" data-parsoid='{"stx":"html","a":{"style":"background-image:u rl(javascript:alert(&#39;boo&#39;))"},"sa":{"style":"background-image:u/**/rl(javascript:alert(&#39;boo&#39;))"}}'>evil</div>
 !! end
 
 !! test
 MSIE CSS safety test: comment in expression
 !! wikitext
 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
-!! html
+!! html/php
 <div style="background-image:expres sion(alert(&#39;boo4&#39;))">evil4</div>
 
+!! html/parsoid
+<div style="background-image:expres sion(alert('boo4'))" data-parsoid='{"stx":"html","a":{"style":"background-image:expres sion(alert(&#39;boo4&#39;))"},"sa":{"style":"background-image:expres/**/sion(alert(&#39;boo4&#39;))"}}'>evil4</div>
 !! end
 
 !! test
 CSS safety test (all browsers): vertical tab (bug 55332 / CVE-2013-4567)
 !! wikitext
 <p style="font-size: 100px; background-image:url\b(https://www.google.com/images/srpr/logo6w.png)">A</p>
-!! html
+!! html/php
 <p style="/* invalid control char */">A</p>
 
+!! html/parsoid
+<p style="/* invalid control char */" data-parsoid='{"stx":"html","a":{"style":"/* invalid control char */"},"sa":{"style":"font-size: 100px; background-image:url\\b(https://www.google.com/images/srpr/logo6w.png)"}}'>A</p>
 !! end
 
 !! test
@@ -16728,10 +16775,13 @@ MSIE 6 CSS safety test: Fullwidth (bug 55332)
 !! wikitext
 <p style="font-size: 100px; color: expression((title='XSSed'),'red')">A</p>
 <div style="top:EXPRESSION(alert())">B</div>
-!! html
+!! html/php
 <p style="/* insecure input */">A</p>
 <div style="/* insecure input */">B</div>
 
+!! html/parsoid
+<p style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"font-size: 100px; color: expression((title=&#39;XSSed&#39;),&#39;red&#39;)"}}'>A</p>
+<div style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"top:EXPRESSION(alert())"}}'>B</div>
 !! end
 
 !! test
@@ -16739,10 +16789,13 @@ MSIE 6 CSS safety test: IPA extensions (bug 55332)
 !! wikitext
 <div style="background-image:uʀʟ(javascript:alert())">A</div>
 <p style="font-size: 100px; color: expʀessɪoɴ((title='XSSed'),'red')">B</p>
-!! html
+!! html/php
 <div style="/* insecure input */">A</div>
 <p style="/* insecure input */">B</p>
 
+!! html/parsoid
+<div style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"background-image:uʀʟ(javascript:alert())"}}'>A</div>
+<p style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"font-size: 100px; color: expʀessɪoɴ((title=&#39;XSSed&#39;),&#39;red&#39;)"}}'>B</p>
 !! end
 
 !! test
@@ -16751,23 +16804,30 @@ MSIE 6 CSS safety test: sup/sub script (bug 55332)
 <div style="background-image:url⁽javascript:alert())">A</div>
 <div style="background-image:url₍javascript:alert())">B</div>
 <p style="font-size: 100px; color: expressioⁿ((title='XSSed'),'red')">C</p>
-!! html
+!! html/php
 <div style="/* insecure input */">A</div>
 <div style="/* insecure input */">B</div>
 <p style="/* insecure input */">C</p>
 
+!! html/parsoid
+<div style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"background-image:url⁽javascript:alert())"}}'>A</div>
+<div style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"background-image:url₍javascript:alert())"}}'>B</div>
+<p style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"font-size: 100px; color: expressioⁿ((title=&#39;XSSed&#39;),&#39;red&#39;)"}}'>C</p>
 !! end
 
-# FIXME: Parsoid fails to sanitize this! See T58846.
 !! test
 Opera -o-link CSS
+!! options
+parsoid=wt2html,html2html
 !! wikitext
 <div
 title="&#100;&#97;&#116;&#97;&#58;&#116;&#101;&#120;&#116;&#47;&#104;&#116;&#109;&#108;&#44;&#60;&#105;&#109;&#103;&#32;&#115;&#114;&#99;&#61;&#49;&#32;&#111;&#110;&#101;&#114;&#114;&#111;&#114;&#61;&#97;&#108;&#101;&#114;&#116;&#40;&#49;&#41;&#62;"
 style="-o-link:attr(title);-o-link-source:current">X</div>
-!! html
+!! html/php
 <div title="data:text/html,&lt;img src=1 onerror=alert(1)&gt;" style="/* insecure input */">X</div>
 
+!! html/parsoid
+<div title="data:text/html,&lt;img src=1 onerror=alert(1)>" style="/* insecure input */" data-parsoid='{"stx":"html","a":{"title":"data:text/html,&lt;img src=1 onerror=alert(1)>","style":"/* insecure input */"},"sa":{"title":"&amp;#100;&amp;#97;&amp;#116;&amp;#97;&amp;#58;&amp;#116;&amp;#101;&amp;#120;&amp;#116;&amp;#47;&amp;#104;&amp;#116;&amp;#109;&amp;#108;&amp;#44;&amp;#60;&amp;#105;&amp;#109;&amp;#103;&amp;#32;&amp;#115;&amp;#114;&amp;#99;&amp;#61;&amp;#49;&amp;#32;&amp;#111;&amp;#110;&amp;#101;&amp;#114;&amp;#114;&amp;#111;&amp;#114;&amp;#61;&amp;#97;&amp;#108;&amp;#101;&amp;#114;&amp;#116;&amp;#40;&amp;#49;&amp;#41;&amp;#62;","style":"-o-link:attr(title);-o-link-source:current"}}'>X</div>
 !! end
 
 !! test
@@ -16780,7 +16840,7 @@ MSIE 6 CSS safety test: Repetition markers (bug 55332)
 <p style="font-size: 100px; color: expresﹽion((title='XSSed'),'red')">E</p>
 <p style="font-size: 100px; color: expresﹼion((title='XSSed'),'red')">F</p>
 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">G</p>
-!! html
+!! html/php
 <p style="/* insecure input */">A</p>
 <p style="/* insecure input */">B</p>
 <p style="/* insecure input */">C</p>
@@ -16789,6 +16849,14 @@ MSIE 6 CSS safety test: Repetition markers (bug 55332)
 <p style="/* insecure input */">F</p>
 <p style="/* insecure input */">G</p>
 
+!! html/parsoid
+<p style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"font-size: 100px; color: expres〱ion((title=&#39;XSSed&#39;),&#39;red&#39;)"}}'>A</p>
+<p style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"font-size: 100px; color: expresゝion((title=&#39;XSSed&#39;),&#39;red&#39;)"}}'>B</p>
+<p style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"font-size: 100px; color: expresーion((title=&#39;XSSed&#39;),&#39;red&#39;)"}}'>C</p>
+<p style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"font-size: 100px; color: expresヽion((title=&#39;XSSed&#39;),&#39;red&#39;)"}}'>D</p>
+<p style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"font-size: 100px; color: expresﹽion((title=&#39;XSSed&#39;),&#39;red&#39;)"}}'>E</p>
+<p style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"font-size: 100px; color: expresﹼion((title=&#39;XSSed&#39;),&#39;red&#39;)"}}'>F</p>
+<p style="/* insecure input */" data-parsoid='{"stx":"html","a":{"style":"/* insecure input */"},"sa":{"style":"font-size: 100px; color: expresーion((title=&#39;XSSed&#39;),&#39;red&#39;)"}}'>G</p>
 !! end
 
 !! test
@@ -16852,7 +16920,6 @@ Expansion of multi-line templates in attribute values (bug 6255)
 
 !! end
 
-
 !! test
 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
 !! wikitext
@@ -16886,6 +16953,7 @@ Tags which are hidden from Tidy cannot pass through the Sanitizer
 ###
 ### Parser hooks (see tests/parser/parserTestsParserHook.php for the <tag> extension)
 ###
+
 !! test
 Parser hook: empty input
 !! wikitext
@@ -18856,7 +18924,6 @@ stuff
 xxx
 !! end
 
-
 !! test
 Handling of &#x0A; in URLs
 !! wikitext
@@ -18865,9 +18932,7 @@ Handling of &#x0A; in URLs
 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
 
 !! html/parsoid
-<ul><li><ul><li> <a rel="mw:ExtLink" href="irc://
-a">irc://
-a</a></li></ul></li></ul>
+<ul><li><ul><li> <a rel="mw:ExtLink" href="irc://%0Aa" data-parsoid='{"stx":"url","a":{"href":"irc://%0Aa"},"sa":{"href":"irc://&amp;#x0A;a"}}'>irc://%0Aa</a></li></ul></li></ul>
 !! end
 
 !! test
@@ -18881,7 +18946,6 @@ Handling of %0A in URLs
 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
 !! end
 
-
 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
 !! test
 5 quotes, code coverage +1 line
@@ -19452,6 +19516,27 @@ File:Foobar.jpg|alt=galleryalt|link=http://www.example.org
 </ul>
 !! end
 
+!! test
+Gallery override link with absolute external link with LanguageConverter
+!! options
+language=zh
+!! input
+<gallery>
+File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
+</gallery>
+!! result
+<ul class="gallery mw-gallery-traditional">
+               <li class="gallerybox" style="width: 155px"><div style="width: 155px">
+                       <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="http://www.example.org"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
+                       <div class="gallerytext">
+<p>caption
+</p>
+                       </div>
+               </div></li>
+</ul>
+
+!! end
+
 !! test
 Gallery override link with malicious javascript (T36852)
 !! options
@@ -19474,7 +19559,7 @@ File:Foobar.jpg|alt=galleryalt|link=" onclick="alert('malicious javascript code!
 
 !! html/parsoid
 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt2" data-mw='{"name":"gallery","attrs":{},"body":{}}'>
-<li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./&quot;_onclick=&quot;alert('malicious_javascript_code!');"><img alt="galleryalt" resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"></div></li>
+<li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./%22_onclick=%22alert('malicious_javascript_code!');"><img alt="galleryalt" resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"></div></li>
 </ul>
 !! end
 
@@ -19504,6 +19589,24 @@ File:Foobar.jpg|link=<
 </ul>
 !! end
 
+!! test
+Serialize gallery without attrs in data-mw
+!! options
+parsoid={
+  "modes": ["html2wt"],
+  "nativeGallery": true
+}
+!! html/parsoid
+<ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt2" data-mw='{"name":"gallery","body":{}}'>
+<li class="gallerycaption">123</li>
+<li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">File:Test.png</span></div><div class="gallerytext"></div></li>
+</ul>
+!! wikitext
+<gallery caption="123">
+File:Test.png
+</gallery>
+!! end
+
 !! test
 HTML Hex character encoding (spells the word "JavaScript")
 !! options
@@ -19787,7 +19890,6 @@ dt/dd/dl test
 
 !!end
 
-
 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
 !! test
 Images with the "|" character in the comment
@@ -19797,7 +19899,7 @@ Images with the "|" character in the comment
 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a>  <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>An <a rel="nofollow" class="external text" href="http://test/?param1=%7Cleft%7C&amp;param2=%7Cx">external</a> URL</div></div></div>
 
 !! html/parsoid
-<figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>An <a rel="mw:ExtLink" href="http://test/?param1=|left|&amp;param2=|x">external</a> URL</figcaption></figure>
+<figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>An <a rel="mw:ExtLink" href="http://test/?param1=%7Cleft%7C&amp;param2=%7Cx" data-parsoid='{"a":{"href":"http://test/?param1=%7Cleft%7C&amp;param2=%7Cx"},"sa":{"href":"http://test/?param1=|left|&amp;param2=|x"}}'>external</a> URL</figcaption></figure>
 !! end
 
 !! test
@@ -20349,8 +20451,8 @@ parsoid=wt2html
 !! html/php
 cat=分类 sort=
 !! html/parsoid
-<p><a rel="mw:WikiLink" href="A" title="A">A</a></p>
-<link rel="mw:PageProp/Category" href="Category:分类"/>
+<p><a rel="mw:WikiLink" href="./A" title="A">A</a></p>
+<link rel="mw:PageProp/Category" href="./Category:分类"/>
 !! end
 
 !! test
@@ -20625,6 +20727,28 @@ Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiw
 # Since Parsoid is starting to emit canonical wikitext for links,
 # [http://example.com http://example.com] will not RT back to that
 # form anymore.
+!! test
+HTML markups with conversion syntax in attribs, nested in other conversion blocks
+!! options
+language=zh variant=zh-cn
+!! wikitext
+-{zh;zh-hans;zh-hant|<span title="-{X}-">A</span>}-
+!! html
+<p><span title="X">A</span>
+</p>
+!! end
+
+!! test
+HTML markups with conversion syntax in attribs, nested in other conversion blocks (not working yet)
+!! options
+language=zh variant=zh-cn disabled
+!! wikitext
+-{<span title="-{X}-">A</span>}-
+!! html
+<p><span title="X">A</span>
+</p>
+!! end
+
 !! test
 Proper conversion of text in external links
 !! options
@@ -22384,82 +22508,6 @@ File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
 
 !! end
 
-!!test
-Gallery override link with absolute external link (bug 34852)
-!! wikitext
-<gallery>
-File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
-</gallery>
-!! html
-<ul class="gallery mw-gallery-traditional">
-               <li class="gallerybox" style="width: 155px"><div style="width: 155px">
-                       <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="http://www.example.org"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
-                       <div class="gallerytext">
-<p>caption
-</p>
-                       </div>
-               </div></li>
-</ul>
-
-!! end
-
-!! test
-Gallery override link with absolute external link with LanguageConverter
-!! options
-language=zh
-!! input
-<gallery>
-File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
-</gallery>
-!! result
-<ul class="gallery mw-gallery-traditional">
-               <li class="gallerybox" style="width: 155px"><div style="width: 155px">
-                       <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="http://www.example.org"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
-                       <div class="gallerytext">
-<p>caption
-</p>
-                       </div>
-               </div></li>
-</ul>
-
-!! end
-
-!!test
-Gallery override link with malicious javascript (bug 34852)
-!! wikitext
-<gallery>
-File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
-</gallery>
-!! html
-<ul class="gallery mw-gallery-traditional">
-               <li class="gallerybox" style="width: 155px"><div style="width: 155px">
-                       <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/%22_onclick%3D%22alert(%27malicious_javascript_code!%27);"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
-                       <div class="gallerytext">
-<p>caption
-</p>
-                       </div>
-               </div></li>
-</ul>
-
-!! end
-
-!!test
-Gallery with invalid title as link (bug 43964)
-!! wikitext
-<gallery>
-File:foobar.jpg|link=<
-</gallery>
-!! html
-<ul class="gallery mw-gallery-traditional">
-               <li class="gallerybox" style="width: 155px"><div style="width: 155px">
-                       <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
-                       <div class="gallerytext">
-                       </div>
-               </div></li>
-</ul>
-
-!! end
-
 !!test
 Language parser function
 !! wikitext
@@ -22721,7 +22769,7 @@ A <ref>
 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
 
 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'>
-<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">This is a <b><a rel="mw:WikiLink" href="Bolded_link" title="Bolded link">bolded link</a></b> and this is a <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}},"i":0}}]}'>transclusion</span>
+<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">This is a <b><a rel="mw:WikiLink" href="./Bolded_link" title="Bolded link">bolded link</a></b> and this is a <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}},"i":0}}]}'>transclusion</span>
 </span></li>
 </ol>
 !!end
index 09e0f07..62d247a 100644 (file)
                                                {
                                                        name: 'hidefilter1',
                                                        label: 'Show filter 1',
-                                                       description: 'Description of Filter 1 in Group 1'
+                                                       description: 'Description of Filter 1 in Group 1',
+                                                       default: true
                                                },
                                                {
                                                        name: 'hidefilter2',
                                                {
                                                        name: 'hidefilter3',
                                                        label: 'Show filter 3',
-                                                       description: 'Description of Filter 3 in Group 1'
+                                                       description: 'Description of Filter 3 in Group 1',
+                                                       default: true
                                                }
                                        ]
                                },
                                                {
                                                        name: 'hidefilter5',
                                                        label: 'Show filter 5',
-                                                       description: 'Description of Filter 2 in Group 2'
+                                                       description: 'Description of Filter 2 in Group 2',
+                                                       default: true
                                                },
                                                {
                                                        name: 'hidefilter6',
                                                {
                                                        name: 'filter8',
                                                        label: 'Group 3: Filter 2',
-                                                       description: 'Description of Filter 2 in Group 3'
+                                                       description: 'Description of Filter 2 in Group 3',
+                                                       default: true
                                                },
                                                {
                                                        name: 'filter9',
                                        ]
                                }
                        },
+                       defaultFilterRepresentation = {
+                               // Group 1 and 2, "send_unselected_if_any", the values of the filters are "flipped" from the values of the parameters
+                               hidefilter1: false,
+                               hidefilter2: true,
+                               hidefilter3: false,
+                               hidefilter4: true,
+                               hidefilter5: false,
+                               hidefilter6: true,
+                               // Group 3, "string_options", default values correspond to parameters and filters
+                               filter7: false,
+                               filter8: true,
+                               filter9: false
+                       },
                        model = new mw.rcfilters.dm.FiltersViewModel();
 
                model.initializeFilters( definition );
 
-               // Empty query = empty filter definition
+               // Empty query = only default values
                assert.deepEqual(
                        model.getFiltersFromParameters( {} ),
-                       {
-                               hidefilter1: false, // The text is "show filter 1"
-                               hidefilter2: false, // The text is "show filter 2"
-                               hidefilter3: false, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
-                               filter7: false,
-                               filter8: false,
-                               filter9: false
-                       },
-                       'Empty parameter query results in filters in initial state'
+                       defaultFilterRepresentation,
+                       'Empty parameter query results in filters in initial default state'
                );
 
                assert.deepEqual(
                        model.getFiltersFromParameters( {
-                               hidefilter1: '1'
-                       } ),
-                       {
-                               hidefilter1: false, // The text is "show filter 1"
-                               hidefilter2: true, // The text is "show filter 2"
-                               hidefilter3: true, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
-                               filter7: false,
-                               filter8: false,
-                               filter9: false
-                       },
-                       'One falsey parameter in a group makes the rest of the filters in the group truthy (checked) in the interface'
-               );
-
-               assert.deepEqual(
-                       model.getFiltersFromParameters( {
-                               hidefilter1: '1',
                                hidefilter2: '1'
                        } ),
-                       {
+                       $.extend( {}, defaultFilterRepresentation, {
                                hidefilter1: false, // The text is "show filter 1"
                                hidefilter2: false, // The text is "show filter 2"
-                               hidefilter3: true, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
-                               filter7: false,
-                               filter8: false,
-                               filter9: false
-                       },
-                       'Two falsey parameters in a \'send_unselected_if_any\' group makes the rest of the filters in the group truthy (checked) in the interface'
+                               hidefilter3: false // The text is "show filter 3"
+                       } ),
+                       'One truthy parameter in a group whose other parameters are true by default makes the rest of the filters in the group false (unchecked)'
                );
 
                assert.deepEqual(
                                hidefilter2: '1',
                                hidefilter3: '1'
                        } ),
-                       {
-                               // TODO: This will have to be represented as a different state, though.
+                       $.extend( {}, defaultFilterRepresentation, {
                                hidefilter1: false, // The text is "show filter 1"
                                hidefilter2: false, // The text is "show filter 2"
-                               hidefilter3: false, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
-                               filter7: false,
-                               filter8: false,
-                               filter9: false
-                       },
+                               hidefilter3: false // The text is "show filter 3"
+                       } ),
                        'All paremeters in the same \'send_unselected_if_any\' group false is equivalent to none are truthy (checked) in the interface'
                );
 
                // The ones above don't update the model, so we have a clean state.
-
+               // getFiltersFromParameters is stateless; any change is unaffected by the current state
+               // This test is demonstrating wrong usage of the method;
+               // We should be aware that getFiltersFromParameters is stateless,
+               // so each call gives us a filter state that only reflects the query given.
+               // This means that the two calls to updateFilters() below collide.
+               // The result of the first is overridden by the result of the second,
+               // since both get a full state object from getFiltersFromParameters that **only** relates
+               // to the input it receives.
                model.updateFilters(
                        model.getFiltersFromParameters( {
                                hidefilter1: '1'
 
                model.updateFilters(
                        model.getFiltersFromParameters( {
-                               hidefilter3: '1'
+                               hidefilter6: '1'
                        } )
                );
 
-               // 1 and 3 are separately unchecked via hide parameters, 2 should still be
-               // checked.
-               // This can simulate separate filters in the same group being hidden different
-               // ways (e.g. preferences and URL).
+               // The result here is ignoring the first updateFilters call
+               // We should receive default values + hidefilter6 as false
                assert.deepEqual(
                        model.getSelectedState(),
-                       {
-                               hidefilter1: false, // The text is "show filter 1"
-                               hidefilter2: true, // The text is "show filter 2"
-                               hidefilter3: false, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
-                               filter7: false,
-                               filter8: false,
-                               filter9: false
-                       },
-                       'After unchecking 2 of 3 \'send_unselected_if_any\' filters via separate updateFilters calls, only the remaining one is still checked.'
+                       $.extend( {}, defaultFilterRepresentation, {
+                               hidefilter5: false,
+                               hidefilter6: false
+                       } ),
+                       'getFiltersFromParameters does not care about previous or existing state.'
                );
 
                // Reset
 
                model.updateFilters(
                        model.getFiltersFromParameters( {
-                               hidefilter1: '1'
+                               hidefilter1: '0'
                        } )
                );
                model.updateFilters(
                        model.getFiltersFromParameters( {
-                               hidefilter1: '0'
+                               hidefilter1: '1'
                        } )
                );
 
                // override.
                assert.deepEqual(
                        model.getSelectedState(),
-                       {
-                               hidefilter1: false, // The text is "show filter 1"
-                               hidefilter2: false, // The text is "show filter 2"
-                               hidefilter3: false, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
-                               filter7: false,
-                               filter8: false,
-                               filter9: false
-                       },
-                       'After unchecking then checking a \'send_unselected_if_any\' filter (without touching other filters in that group), all are checked'
+                       defaultFilterRepresentation,
+                       'After checking and then unchecking a \'send_unselected_if_any\' filter (without touching other filters in that group), results are default'
                );
 
                model.updateFilters(
                );
                assert.deepEqual(
                        model.getSelectedState(),
-                       {
-                               hidefilter1: false, // The text is "show filter 1"
-                               hidefilter2: false, // The text is "show filter 2"
-                               hidefilter3: false, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
+                       $.extend( {}, defaultFilterRepresentation, {
                                filter7: true,
                                filter8: false,
                                filter9: false
-                       },
+                       } ),
                        'A \'string_options\' parameter containing 1 value, results in the corresponding filter as checked'
                );
 
                );
                assert.deepEqual(
                        model.getSelectedState(),
-                       {
-                               hidefilter1: false, // The text is "show filter 1"
-                               hidefilter2: false, // The text is "show filter 2"
-                               hidefilter3: false, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
+                       $.extend( {}, defaultFilterRepresentation, {
                                filter7: true,
                                filter8: true,
                                filter9: false
-                       },
+                       } ),
                        'A \'string_options\' parameter containing 2 values, results in both corresponding filters as checked'
                );
 
                );
                assert.deepEqual(
                        model.getSelectedState(),
-                       {
-                               hidefilter1: false, // The text is "show filter 1"
-                               hidefilter2: false, // The text is "show filter 2"
-                               hidefilter3: false, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
+                       $.extend( {}, defaultFilterRepresentation, {
                                filter7: false,
                                filter8: false,
                                filter9: false
-                       },
+                       } ),
                        'A \'string_options\' parameter containing all values, results in all filters of the group as unchecked.'
                );
 
                model.updateFilters(
                        model.getFiltersFromParameters( {
-                               group3: 'filter7,filter8,filter9'
+                               group3: 'filter7,all,filter9'
                        } )
                );
                assert.deepEqual(
                        model.getSelectedState(),
-                       {
-                               hidefilter1: false, // The text is "show filter 1"
-                               hidefilter2: false, // The text is "show filter 2"
-                               hidefilter3: false, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
+                       $.extend( {}, defaultFilterRepresentation, {
                                filter7: false,
                                filter8: false,
                                filter9: false
-                       },
+                       } ),
                        'A \'string_options\' parameter containing the value \'all\', results in all filters of the group as unchecked.'
                );
 
                );
                assert.deepEqual(
                        model.getSelectedState(),
-                       {
-                               hidefilter1: false, // The text is "show filter 1"
-                               hidefilter2: false, // The text is "show filter 2"
-                               hidefilter3: false, // The text is "show filter 3"
-                               hidefilter4: false, // The text is "show filter 4"
-                               hidefilter5: false, // The text is "show filter 5"
-                               hidefilter6: false, // The text is "show filter 6"
+                       $.extend( {}, defaultFilterRepresentation, {
                                filter7: true,
                                filter8: false,
                                filter9: true
-                       },
+                       } ),
                        'A \'string_options\' parameter containing an invalid value, results in the invalid value ignored and the valid corresponding filters checked.'
                );
        } );
                );
        } );
 
-       QUnit.test( 'reapplyActiveFilters - "default" exclusion rules', function ( assert ) {
+       QUnit.test( 'setFiltersToDefaults', function ( assert ) {
                var definition = {
                                group1: {
                                        title: 'Group 1',
                                                {
                                                        name: 'hidefilter1',
                                                        label: 'Show filter 1',
-                                                       description: 'Description of Filter 1 in Group 1'
+                                                       description: 'Description of Filter 1 in Group 1',
+                                                       default: true
                                                },
                                                {
                                                        name: 'hidefilter2',
                                                {
                                                        name: 'hidefilter3',
                                                        label: 'Show filter 3',
-                                                       description: 'Description of Filter 3 in Group 1'
+                                                       description: 'Description of Filter 3 in Group 1',
+                                                       default: true
                                                }
                                        ]
                                },
                                                {
                                                        name: 'hidefilter5',
                                                        label: 'Show filter 5',
-                                                       description: 'Description of Filter 2 in Group 2'
+                                                       description: 'Description of Filter 2 in Group 2',
+                                                       default: true
                                                },
                                                {
                                                        name: 'hidefilter6',
                        model.getFullState(),
                        {
                                // Group 1
-                               hidefilter1: { selected: false, active: true },
+                               hidefilter1: { selected: true, active: true },
                                hidefilter2: { selected: false, active: true },
-                               hidefilter3: { selected: false, active: true },
+                               hidefilter3: { selected: true, active: true },
                                // Group 2
                                hidefilter4: { selected: false, active: true },
-                               hidefilter5: { selected: false, active: true },
+                               hidefilter5: { selected: true, active: true },
                                hidefilter6: { selected: false, active: true },
                        },
-                       'Initial state: all filters are active.'
+                       'Initial state: all filters are active, and select states are default.'
                );
 
                // Default behavior for 'exclusion' type with only 1 item selected, means that:
                                        ]
                                }
                        },
+                       defaultFilterRepresentation = {
+                               // Group 1 and 2, "send_unselected_if_any", the values of the filters are "flipped" from the values of the parameters
+                               hidefilter1: false,
+                               hidefilter2: true,
+                               hidefilter3: false,
+                               hidefilter4: true,
+                               hidefilter5: false,
+                               hidefilter6: true,
+                               // Group 3, "string_options", default values correspond to parameters and filters
+                               filter7: false,
+                               filter8: true,
+                               filter9: false
+                       },
                        model = new mw.rcfilters.dm.FiltersViewModel();
 
                model.initializeFilters( definition );